Home / Archive by category ".NET" (Page 20)

Configuration sections the easy way

Have you ever needed to implement configuration sections for the application configuration file with C#? If you want to implement such a section for the application configuration file you need to dive deep into the System.Configuration namespace which offers quite powerful collections and attribute based configuration methods to implement configuration sections. But there is actually an easier way to implement such a section without divining deep into System.Configuration. The solution is serialization!

Continue reading

NMock2 Release Candidate Version 2.0 is out

The first release candidate of version 2.0 of NMock2 – a .net dynamic mocking framework – is published.

Check it out at: sourceforge.net

You can provide feedback at: NMock2 forum

Release Notes:

  • virtual/abstract classes can now be mocked (with default or transparent mock style)
  • Stack traces of exceptions thrown in event handlers of events fired on mocks are preserved
  • Source is now on Visual Studio 2008 (target framework is still .net 2.0)
  • Events of inherited interfaces can now be fired on mocks
  • internal interfaces of signed assemblies can now be mocked (contribution of Matthias Weibel)
  • Swallowed exceptions are rethrown in VerifyAllExpectationsHaveBeenMet

Delegate.DynamicInvoke for .NET Compact Framework

As you might already know I’m a certified windows mobile application developer. My speciality is hybrid application development for applications which target both the full .NET framework platform and also the mobile platform. Of course nobody wants to write the same code for each platform again so you have to come up with some tricks and solutions to overcome some limitations on the compact framework.

Continue reading