• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

If you change public methods in your libraries, increase the version number

Mark R

Diamond Member
Microsoft, I'm looking at you.

I was writing a small app for work, which needs to run on an old machine running XP SP1 with .NET framework 2.0.

So I build the app for .NET 2.0 using VS 2012. All compiles fine. All runs fine on my machine, and a test VM with .NET 2.0 only.

Take it to work and it dies with a System.MissingMethodException when it comes across a call to WaitHandle.WaitOne(int)

After a number of hours of headscratching, I find the problem. MS changed the public interface to WaitHandle.WaitOne in the .NET 2.0 SP2 (which I had on my VM, but was not present on the work machine), adding several overloads to the method. More importantly, both DLLs had the exact same version number, so there was no way to tell which was which, unless you knew whether SP2 was installed or not. Further VS2012 did not provide any warnings that the method I was calling was not supported in the targeted framework (nor indeed, does the MSDN documentation).

Edited title to remove profanity. No cursing in the technical forums, please.
Markbnj
Programming mod
 
Last edited by a moderator:
The 2.0 years for .Net were scary years 🙂. It was still very much a fledgling framework. It really wasn't until .Net 3.0 that things really stabilized.

If I remember my history correctly, .Net 1.0 was out for just a short while before 2.0 came out and then there were several service packs that followed.
 
Back
Top