ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

problems with reusing VIs with .NET controls

I have some hardware devices that use .NET for control.  I am only able to get them to work if I create a LabVIEW project and place the .NET .dll files in the same directory or a subdirectory of the project file.  However, I want to be able to use the instrument VIs in other projects.  If I try to add an instrument VI to the new project, the .NET container is on longer able to load the .NET control.

 

My file structure is like this:

 

top/
├── project 1 ├── project 2 └── instruments/ ├── instrument 1
├── instrument 2

Ultimately I want to be able to make instrument VIs that make use of .NET controls that I can re-use for other projects.  Up until now I have been managing projects by file structure and not using LabVIEW project files.

 

Thanks.

 

0 Kudos
Message 1 of 3
(2,476 Views)

Hi laserduo,

 

I have some hardware devices that use .NET for control. I am only able to get them to work if I create a LabVIEW project and place the .NET .dll files in the same directory or a subdirectory of the project file.

Usually all .NET related code is placed "somewhere" in the system, installed by a proper setup tool and managed by the OS.

I never placed those .NET dlls in the project folder…

Maybe this default way would help to make the .NET component available in all your projects?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 3
(2,393 Views)

According to https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000PAm6SAG&l=en-CA, if they're in the Global Assembly Cache they will be found automatically.  I'll look into doing that manually.  The drivers I received (from Thorlabs) do not install to the GAC automatically.

0 Kudos
Message 3 of 3
(2,355 Views)