How to diagnose COM-callable wrapper object creation failure?

You can use the assembly binding failure logging feature – it needs to be enabled and then you can use the fusion log viewer to see the results http://msdn.microsoft.com/en-us/library/e74a18c4(v=vs.110).aspx Not sure how you will get this onto your clients machines. When I first read this my first thought was given it seems most common on … Read more

What is the new GlobalSection in a VS2017 15.3 solution file?

According to Mastering Visual Studio book the ExtensibilityGlobals (and ExtensibilityAddIns) section included for the benefit of add-in authors. ExtensibilityGlobals used to store global information about the solution. So it is clearly generated by(or for) some 3rd party tools. The only discussion about SolutionGuid is here, which is generated by CMake and they advise that you … Read more

What is the difference between System.Drawing.Color and System.Windows.Media.Color?

System.Windows.Media.Color is part of the System.Windows.Media namespace: Provides types that enable integration of rich media, including drawings, text, and audio/video content in Windows Presentation Foundation (WPF) applications. System.Drawing.Color is part of the System.Drawing namespace: The System.Drawing namespace provides access to GDI+ basic graphics functionality. More advanced functionality is provided in the System.Drawing.Drawing2D, System.Drawing.Imaging, and System.Drawing.Text … Read more

Why is the Process class in the Diagnostics namespace?

Well, according to the documentation, “The System.Diagnostics namespace provides classes that allow you to interact with system processes, event logs, and performance counters.” So I guess by definition it fits. 🙂 But yes, it does seem a bit like an overloading of terms by putting it next to things a bit more obviously diagnostics-related (tracing, … Read more

Activator.CreateInstance Vs new

This overload of the “Activator.CreateInstance” method is used by compilers to implement the instantiation of types specified by type parameters using generics. Say you have the following method: public static T Factory<T>() where T: new() { return new T(); } The compiler will convert the “return new T();” to call “CreateInstance”. In general, there is … Read more

Is it OK to use HttpRuntime.Cache outside ASP.NET applications?

I realize this question is old, but in the interest of helping anyone who finds this via search, its worth noting that .net v4 includes a new general purpose cache for this type of scenario. It’s in the System.Runtime.Caching namespace: https://msdn.microsoft.com/en-us/library/dd997357(v=vs.110).aspx The static reference to the default cache instance is: MemoryCache.Default