03-20-2007 12:27 PM
03-20-2007 03:11 PM
You do not say which version of LabVIEW you are using. But in general unless you have the DLL in one of the system locations (Windows or System32 directory) You will want to have the DLL included with your app. However LabVIEW by default will put any support files into a seperate data directory when building an application. You can override that in the build settings for your project, by specifying a different location for the DLL to be moved to when building the executable or DLL. I regularely change my DLLs to be in the executables directory instead of the data directory (and usually don't have a data directory in my applciations at all but several other ones).
@dpatch wrote:I am using LabView 7.0 and am loading a DLL built in C. From within the development environment everything is fine. However when I build an executable, it must be run on the target machine in the same directory as on the development machine. This is because the development environment "adds" the fully qualified path to the DLL (even if you put the dll name in with out the path).How can I get LV to not add the dll's path and look in the application directory for the dll. Is this a LabView 7.0 bug?
03-22-2007 06:26 PM
03-23-2007 03:15 AM
Sorry, I must have been with my mind a little of line. Yes you said 7.0 and I have to admit that I only currently use 7.1.1. and a bit of 8.2 actively so I'm not 100% sure if this applies to 7.0 as well. I think that the DLL path feature for the CLN is actually a 8.2 feature unless you want to use obscure and unreleased features.
@dpatch wrote:
I am not sure what you meant when you said that I did not give the version of LV that I was using. I think if you re-read you will see that I mentino it twice! I believe the solution you mention is in a later version of LV...maybe 8.0+ However, as I mentioned, I am using version 7.0. In this version if you enter only the DLL name in the Code Interface Node, LV will add the FQPN of the calling VI. I believe I read that in version 8.0 you can specify the path of the DLL at run-time. You can not do this is version 7.