i'm trying to open new Calc document, and i'm getting this error:
System.IO.FileLoadException: Mixed mode assembly is built against version 'v2.0.50727' of the runtime and cannot be loaded in the 4.0 runtime without additional configuration information.
Cli references are inlcuded in project.
void OpenSpreadsheetClick(object sender, EventArgs e)
{
XComponentContext oStrap = uno.util.Bootstrap.bootstrap();
//The next step is to use OpenOffice.org's service manager to create a desktop:
XMultiServiceFactory oServMan = (XMultiServiceFactory) oStrap.getServiceManager();
XComponentLoader oDesk = (XComponentLoader) oServMan.createInstance("com.sun.star.frame.Desktop" );
string url = @"private:factory/scalc";
PropertyValue[] propVals = new PropertyValue[0];
XComponent oDoc = oDesk.loadComponentFromURL(url, "_blank", 0, propVals);
}
How to fix it? Tnx for help :)