I've got some winforms partial classes marked [Obsolete]
. Unlike when applying this to methods, I get no warning after building. Is this because it's set on a partial class? I can't set it in the designer too, because that code can/will be regenerated. Anything I can do about it with attributes? I don't want to throw an exception or something similar.
pritaeas 2,211 ¯\_(ツ)_/¯ Moderator Featured Poster
Recommended Answers
Jump to PostYou normally should at least get a warning if some code from obsolete code is used. Is the main partial form part missing?
Jump to PostI would do a little re-design there. Whilst
const
ought to be flagged by Obsolete, I would redesign and make a public property that returns your const. Mark the property as obsolete and it should flag it.
All 6 Replies
ddanbe 2,724 Professional Procrastinator Featured Poster
deceptikon 1,790 Code Sniper Team Colleague Featured Poster
pritaeas 2,211 ¯\_(ツ)_/¯ Moderator Featured Poster
pritaeas 2,211 ¯\_(ツ)_/¯ Moderator Featured Poster
Ketsuekiame 860 Master Poster Featured Poster
pritaeas 2,211 ¯\_(ツ)_/¯ Moderator Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.