LabWindows/CVI 8.0 and greater provide several options for working with .NET
assemblies. You can use the .NET Library
to invoke methods and set/get properties from .NET assemblies.
Additionally, LabWindows/CVI also provides the Create
LabWindows/CVI .NET Controller feature, which you can use to generate a
LabWindows/CVI wrapper for a .NET assembly which is the in form of an
instrument driver, source file, and header file. You also can use the
.NET Library functions in conjunction with the generated wrapper.
Refer to the LabWindows/CVI shipping examples located in the <CVI>\samples\dotnet\ directory for some examples. Also check out the .NET
Library help (Open the LabWindows/CVI Help, switch to the Contents tab
and expand Library Reference >> .NET Library. These sections go
into great detail on working with .NET assemblies.)
Hope this helps!Best Regards,
Header files don't exist in VB.NET, since the only output of the VB.NET compiler is .NET assemblies. The .NET Controller wizard generates a C wrapper around your assembly. As I mentioned earlier, the wrapper is in the form of an instrument driver, source file, and
header file.
That error you mentioned doesn't have anything to do with incorrect header files. Rather, the problem is that the .NET CLR is unable to locate the assemblies for which the wrapper was created for. The key concept to remember when calling .NET assemblies from CVI is that iIf you plan to use an assembly in LabWindows/CVI that is not located in the Global Assembly Cache (GAC) or in the current directory of the calling
executable, then you must call CDotNetRegisterAssemblyPath to
register the assembly. If you use an assembly that is located in the GAC or in
the current directory of the calling executable, it is not necessary to call
CDotNetRegisterAssemblyPath to use the assembly;
the assembly is registered automatically.
If you don't put the assembly in the one of the above locations, then you need to make sure to call CDotNetRegisterAssemblyPath and pass the full path to the assembly before calling CDotNetLoadAssembly.
Best Regards,Message Edited by Jonathan N on 04-14-2008 08:44 AM