How to solve: Microsoft Visual Studio 2008 designer hangs after installing Microsoft Office 2010 and Microsoft Visual Studio 2010

If you install Microsoft Office 2010 and Microsoft Visual Studio 2010 on an machine running Microsoft Visual Studio 2008 and Microsoft Office 2007, you might run into the problem that the designer of the Microsoft Visual Studio 2008 hangs. To resolve this problem restore the Microsoft Visual Studio Web Authoring …

How to determine if a given path is a relative path in C#

If you want to determine if a given path is a relative path in C#, you can use the System.IO.Path.IsPathRooted function: bool isPathRooted = Path.IsPathRooted("Test.txt"); Console.WriteLine(isPathRooted); Result: False bool isPathRooted = Path.IsPathRooted(@"\\nas\Test.txt"); Console.WriteLine(isPathRooted); Result: True bool isPathRooted = Path.IsPathRooted(@"C:\Test.txt"); Console.WriteLine(isPathRooted); Result: True

Silverlight 3 How to resolve: Error Unknown element: OutOfBrowserSettings.WindowsSettings when enabeling out of browser mode

If you get the an error when enabeling out fo browser mode in Silverlight 3, this is because you’re enabeling it in the wrong way. Don’t use the AppManifest.xml but the project properties and check the “Enable running application out of the browser”. This will generate a OutOfBrowserSettings.xml file, like: …

ReportViewer control does not show default images on IIS7

If you use the ReportViewer control in you’re C# web application and the ReportViewer does not show the default images (refresh button etc) then you can check you’re web.config if it contains the correct axd handler: <add name=": Reserved-ReportViewerWebControl-axd" path="Reserved.ReportViewerWebControl.axd" verb="*" type="Microsoft.Reporting.WebForms.HttpHandler" resourceType="Unspecified" preCondition="integratedMode" /> In mine web.config it look …

How to sum TimeSpan in LINQ with C#

If you want to sum TimeSpan properties in LINQ with C#, use: List<TimeSpan> list = new List<TimeSpan>             { new TimeSpan(1), new TimeSpan(2), new TimeSpan(3) }; // TimeSpan.Zero is the initial offset, in this case 0 ticks // subtotal is used to sum to items in the list // t is …

How to start suspended MSDN subscription download with TransferMgr.exe

When you download software with you’re MSDN subscription account and suspend you’re download, you can resume the download by starting “C:\Windows\Downloaded Program Files\TransferMgr.exe” and press resume. I found the location of this executable by starting the taskmanager > right click “Microsoft File Transfer Manager” > Go To Process > right …

SSIS 2008 Script Task using and reference a custom none GAC (not signed) assembly

  If you reference an custom none GAC assembly from you’re SSIS 2008 script task, you can get an exception, stating the assembly could not be found. Error Error: 0x1 at Filesysteem opschoning: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. —> System.IO.FileNotFoundException: Could not load file …