From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
05-19-2012 10:46 AM
hi ,
now I need to call a dll named SajetConnect.dll, this dll will create log file and ini file automaticly when i call it .
Attached vi call this dll , there is no log file and ini file created, but the exe file what I build from this VI work well for it .
I also call thie dll using C# and it still work well.
So it seems some path setting issue happened from me , thanks for your help to have a look for my trouble ,thanks !!!!
attached list
Untitled 2.vi VI
New Folder\123\Application.exe create LOG SAJET.INI SajetConnect.ini when you run this exe to call dll
Solved! Go to Solution.
05-19-2012 05:00 PM - edited 05-19-2012 05:04 PM
Without seeing the DLL source code there is very little we can do but shooting in the blue. And I have no bullets to spare in this for the moment, except maybe that the DLL tries to create those files in the directory where the executable is located. This would be in the deveopment environment the directory where labview.exe is located. But since Windows Vista users do not have write access to that directory anymore. Some INI file functionality is virtualized in those Windows versions and redirected to some user specific shadow location, but only if your application uses Windows API INI file functions. Otherwise the write access will simply fail and unless you handle those errors somehow and pass them to the caller you won't see them.
05-21-2012 12:56 AM
Thanks!
Actually, I find the ini file and Log file have been created in folder (C:\Program Files\National Instruments\LabVIEW 8.6).
it means that the dll will create the file in the folder where the *.exe call the all.
05-21-2012 12:59 AM
@菊花烧饼 wrote:
Thanks!
Actually, I find the ini file and Log file have been created in folder (C:\Program Files\National Instruments\LabVIEW 8.6).
it means that the dll will create the file in the folder where the *.exe call the all.
This will not work for normal users under Windows Vista and newer unless you explicitedly change the permission of that directory to allow write access for normal users.