08-27-2024 02:24 PM
I am using a inhouse developed .NET dell to communicate with some hardware. I am calling it from LabVIEW using .NET constructor nodes, and the LabVIEW VIs is called from Teststand. That works fine until I deploy it, then it either says the VIs are broken (if I use Teststand deployment utillity to make packed Libary), or it can't load after deploy (if I am not packing it to packed libary)
I have found out the solution might be, that I make a LabVIEW packed Library around the .dll where I can call al the functions, that can deploy and also run, if i place the .DLL in the Windows GAC. But optimal I would like to have the dll in same location as the LabVIEW project, so it is easier to update together.
And the solution I have now is not very stable.
How do you organize it?
Solved! Go to Solution.
08-27-2024 11:49 PM
Working with .net assemblies can be a challenge 😉
If you (like me) are NOT using the GAC, you need to make sure, that the relative path between the VIs and the DLL always stay the same. I guess you will need to configure this on the deployment utility as well.
When using PPLs referring to DLL, the same more or less applies.
My strategy is to have a folder for each library, in this context a DLL is also a lib
The LabVIEW lib "knows": I always have to go one directoy up and look for the dll-directory (naming scheme has to be in place)
This way, I can also use the same dll from differnt libs, which is a use case for me.
This folder structure has to be maintained strictly during development and deplyoment
I have seen people using a common directory liek C:\My Libraries where thy put in all there stuff. Can be done as well.
08-28-2024 01:24 AM
Hi Oli
Thank you for the answer, I am quite sure it was also how I was trying to do it, and it does also work fine before I deploy Teststand.
So it is probably more experience with how to set up Teststand Deployment Utillity with DLLs used in LabVIEW, that is the question for me.
But I will definitely look at the C:\My Libraries solution.
Thanks again
Anders
08-28-2024 04:58 AM
Just stumbled over https://youtu.be/ktHxOe65my8?feature=shared&t=1256
09-02-2024 02:59 AM
Hi again
I have tried Oli's suggestions, but it has not brought me any further.
It turned out the solution with adding it to Windows GAC was not a a stable solution.
I am using a .NET constructor .dll to control some hardware. It is working fine in development mode, but when I try to deploy Teststand, I get following error:
My LabVIEW deployment settings are:
I have tried:
I do always get same issue, and I can’t find more debug info, because the Vis are not broken when I open them in LabVIEW.
Anybody with a suggestion?
09-02-2024 04:22 AM
Looking at the screeshot.... does the folder name just accidentally contain the String OneDrive or is this actually mapped to a sharepoint?
09-02-2024 05:02 AM
Yes you are right;)
I just made a small test project in documents, where I can share screenshot etc, så it has no influence on the issue.
The real project is under c:\Repositories\...
Regards Anders
09-03-2024 01:56 AM
Sounds strange....
We are using a PPL based HAL (which also call DLLs)...
I guess this has someting to do with how "close" your deployment folder structure to your development folder structure.
We try to keep it as close as possible...
Probably doesn't help you ...
09-06-2024 02:40 AM
It turned out to be a LabVIEW bug 2645388 in 2024Q1, an upgrade to 2024Q3 solved the problem.
Kudos to NI support.