03-23-2020 12:45 PM
03-23-2020 12:52 PM
The windows that pop up for this are "Windows" windows, and remember your last directory used in an attempt to be helpful.
What I'd recommend is that you just add both the 2015 and 2018 locations to your "Quick access" list in Windows, which will cause them to be just one click away whenever LabVIEW asks you where to save things.
03-23-2020 02:51 PM
As Kyle said that is a "Windows thing" and not LabVIEW. Other that the suggestion of putting both directories on your Quick Access there is nothing you can do except for always try to be aware of what directory you are working on.
03-23-2020 03:33 PM
Argh. I always hide Quick Access, never look there, probably not going to start.
Not much of a Windows user/programmer here, but is LabVIEW using iFileDialog or the older OpenFileDialog?
Both seem to have a way to specify the initial directory, maybe LabVIEW is not setting it.
IFileDialog::SetFolder | Sets a folder that is always selected when the dialog is opened, regardless of previous user action. |
property System::String ^ InitialDirectory { System::String ^ get(); void set(System::String ^ value); };
Thanks anyway. I thought I was missing something obvious.
03-23-2020 05:30 PM
I'm not sure if this helps or not, but I believe you can set the startup path on a path control.
03-23-2020 07:01 PM
It uses the old OpenFileDialog Win32 API. And while it allows your app to select a start directory when you display that dialog, it leaves that empty for the file select dialog. In old Windows versions that caused the File dialog to start at the process global current directory. At some point the Windows folks apparently thought it a good idea to change that to a system global file selection directory.
Changing that in LabVIEW now would likely alienate about as many users as the current behavior does annoy now.
03-25-2020 09:32 AM
@rolfk wrote:
At some point the Windows folks apparently thought it a good idea to change that to a system global file selection directory.
Changing that in LabVIEW now would likely alienate about as many users as the current behavior does annoy now.
Never really liked LabVIEW's behavior, even with a single LabVIEW instance running, as it keeps going to the directory of the last opened VI, where I would expect, when pulled down from the Menu/File of a given VI, Front Panel or Block Diagram window, to open in the directory where that VI in the file system.
At least I think that's how most other programs behave (emacs certainly does). And when one LabVIEW can change what I would expect to be the "current working directory" of another running LabVIEW, it is certainly not expected.
Isn't this something that could be an option in LabVIEW.ini? Defaulting to current (mis-)behavior?