Skip to main content

Posts

Showing posts from January, 2010

Power Automate: SharePoint Copy file action fails on file names with a plus (+) sign

Using class extensions in .NET 3.0 like in .NET 3.5

A customer had the requirement to develop his solution with .NET 3.0 framework. I was already used to the new and nice features of .NET 3.5 framework, especially the class extension feature. A simple example for a class extension would be like this: public class ReverseString { public static void Main() { string s = "Hello World!" ; string r = s.Reverse(); } } static class StringHelpers { public static string Reverse( this string s) { char [] c = s.ToCharArray(); Array.Reverse(c); return new string (c); } } In order to use the same feature under .NET 3.0 you can use the following trick: First create an empty class file (e.g. AttributeExtension.cs) and add this class to your project. Secondly put the following code in that class: using System; namespace System.Runtime.CompilerServices { /// <summary> /// Indicates that a method is an extension method, /// or that a class or assembly contains ex

Remove .NET Framework launch condition from a MSI file

As I created a VS2008 Web Setup project I always had to specify the .Net Framework launch condition. I found no way to deactivate this on the UI. To work around this problem I used Orca 3.1 (which also enables support and correct handling of x64 application files). Open up your MSI file and go to Edit->Find and search for: VSDCA_VsdLaunchConditions Delete all rows that contain this word and save the MSI file. Now you should have gone rid of this annoying behavior/feature.

The installer was interrupted before Application could be installed...

This error occured as I tried to install a custom installer web project, built with VS2008 in 32-Bit or 64-Bit mode on my 64-Bit target system. To get more details on that error, I tried the following command in my console window: msiexec /i /l*vx install.log The log file pointed out the following error: MSI (c) (60:54) [17:00:43:240]: Attempting to enable all disabled privileges before calling Install on Server MSI (c) (60:54) [17:00:43:240]: Connected to service for CA interface. INFO : [06/22/2008 17:00:43:346] [SetTARGETSITE]: Custom Action is starting... INFO : [06/22/2008 17:00:43:347] [SetTARGETSITE]: CoInitializeEx - COM initialization Apartment Threaded... ERROR : [06/22/2008 17:00:43:349] [SetTARGETSITE]: FAILED: -2147221164 ERROR : [06/22/2008 17:00:43:349] [SetTARGETSITE]: Custom Action failed with code: '340' INFO : [06/22/2008 17:00:43:350] [SetTARGETSITE]: Custom Action completed with return code: '340' Action ended 17:00:43: WEBCA_SetTARGETSITE.