This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Re: .Net 4 dll Error
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 28, 2011
02:33 PM
.Net 4 dll Error
Anyone successfull calling a .net 4 dll with installshield 2011. I keep getting error -2147219705 (null). Anyone know what that error means. Using a Basic MSI project. Tried with the Custom action wizard and with DotNetCoCreateObject.
(5) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Apr 29, 2011
12:13 PM
Does this happen with all .NET assemblies you have tried to call or only one? Can you reproduce this behavior with a sample assembly?
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎May 03, 2011
10:08 AM
Not yet I am going to try one of the sample dlls today. I will let you know the out come.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎May 03, 2011
11:28 AM
I get the same error using the SampleClassLibrary.dll. code below, just trying to load it right now, can't seem to get past loading
szDotNetDll = WindowsFolder ^ "temp\\SampleClassLibrary.dll";
szClass ="SampleClassLibrary.ChooseItem";
MessageBox("SaveConnString", INFORMATION);
MessageBox(szDotNetDll, INFORMATION);
UseDLL(szDotNetDll);
try
set SaveString = DotNetCoCreateObject(szDotNetDll, szClass, "");
catch
SprintfBox (INFORMATION, "Error","Error occured: %i\n\n%s\n\n%s", Err.Number, Err.Description, Err.LastDllError);
abort;
endcatch;
szDotNetDll = WindowsFolder ^ "temp\\SampleClassLibrary.dll";
szClass ="SampleClassLibrary.ChooseItem";
MessageBox("SaveConnString", INFORMATION);
MessageBox(szDotNetDll, INFORMATION);
UseDLL(szDotNetDll);
try
set SaveString = DotNetCoCreateObject(szDotNetDll, szClass, "");
catch
SprintfBox (INFORMATION, "Error","Error occured: %i\n\n%s\n\n%s", Err.Number, Err.Description, Err.LastDllError);
abort;
endcatch;
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎May 09, 2011
09:15 AM
Fixed issue, had the developer change the classes and methods to non static.
Also the sample dll can not be used with the dotnetcocreateobject function.
Also the sample dll can not be used with the dotnetcocreateobject function.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 15, 2012
06:47 AM
You can set assembly: ComVisible(false) to assembly: ComVisible(true). The exception will not come.
![](/skins/images/8CE4FAD0DE6F3A6F9D0567434D2D2DAE/responsive_peak/images/icon_anonymous_message.png)