Monday, 9 May 2011

"Debug" setting: OpenExchange and Microsoft Visual C# 2010 Express

The programmation of a Windows Forms Application under Microsoft Visual C# 2010 Express generates an error message "Type initializer 'Sdl.ProjectAutomation.FileBased.LicenseUtils' threw an exception" if the output path has not been set correctly.
The default setting is "bin\Release\".

To program with the SDL API, the output path must be set on C:\Program Files\SDL\SDL Trados Studio\Studio1 (the folder where Studio is installed), so that no license error doesn't prevent the program to run.

I first thought I had to enter the path here (Properties/Build):

but it didn't work...

It's necessary to set this path in the "advanced build configurations":
Go to "Tools"-> "Options..."
Tick the box "Show all settings" (bottom, left)
Click "Projects and Solutions" -> "General" in the menu on the left
and tick the box "Show advanced build configurations"

Now you get another window in your build settings:

After you entered the "Studio" path, you can test your application from Visual C# 2010Express.

No comments:

Post a Comment