Page 1 of 2
Admin.ini - [Paths]: Environment variables support
Posted: 11 Jan 2025 14:10
by highend
Can you please add environment variable support to the keys in [Paths] for the Admin.ini file?
So that e.g. this will work:
Code: Select all
[Paths]
FileTagDat="%USERPROFILE%\OneDrive\DB.dat"
Scripts="D:\XYusers\%USERNAME%\Scripts"
etc.
Thanks!
Re: Admin.ini - [Paths]: Environment variables support
Posted: 12 Jan 2025 15:22
by admin
Makes sense, next beta.
Re: Admin.ini - [Paths]: Environment variables support
Posted: 12 Jan 2025 15:56
by highend
Thanks!
Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 00:11
by highend
It seems the entry for Paper isn't working at all atm...
E.g.:
Paper="%USERPROFILE%\OneDrive\XYplorer\Paper"
If you invoke Help - Various Information
it shows that Paper still points to the standard path (in XY's data folder) and not to the path defined by Admin.ini
Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 09:57
by admin
Works here.
Is "%USERPROFILE%\OneDrive\XYplorer\Paper" an existing path?
Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 10:13
by highend
It is.
Try this
Admin.ini:
Code: Select all
[Paths]
FileTagDat="%USERPROFILE%\OneDrive\XYplorer\DB\SharedTags.dat"
Catalogs="%USERPROFILE%\OneDrive\XYplorer\Catalogs"
NewItems="%USERPROFILE%\OneDrive\XYplorer\NewItems"
Paper="%USERPROFILE%\OneDrive\XYplorer\Paper"
Scripts="%USERPROFILE%\OneDrive\XYplorer\Scripts"
[Tags]
TagDatSafeSave=1
TagDatOpenTryMsecs=5000
TagFlags=1
TagDatModCheckMsecs=2000
Paper is pointing to the wrong folder!
Now remove the
[Tags] section and...
Paper will point to the correct folder!
oO
Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 10:54
by admin
Wow, interesting case. My super-optimized INI reader could fail to find a key if the user chose a certain sequence of keys. Fixed in next beta.

Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 17:05
by highend
with 0602 all paths from the Admin.ini are now ignored regardless if the [Tags] section exists additionally or not...
Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 17:20
by admin
Not here.

Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 17:41
by highend
Re: Admin.ini - [Paths]: Environment variables support
Posted: 13 Jan 2025 17:54
by admin
Crazy. Has to wait till tomorrow.
Re: Admin.ini - [Paths]: Environment variables support
Posted: 14 Jan 2025 17:18
by admin
Tried with Win10: No problem. Can't explain what you get.
Anyway, I applied a different and better fix now to the original problem. Next beta.
Re: Admin.ini - [Paths]: Environment variables support
Posted: 14 Jan 2025 18:12
by Daniel0312
Hi,
I had the same behavior as highend.
I did some tests and messed my licence and... surprise it worked with expired license.
Hope it helps.
Re: Admin.ini - [Paths]: Environment variables support
Posted: 14 Jan 2025 18:45
by highend
It's back to the original behaviour with 0603
If the [Tags] section is in place, Paper points to the standard folder, if it's removed, it respects the setting from the Admin.ini
Re: Admin.ini - [Paths]: Environment variables support
Posted: 14 Jan 2025 19:07
by admin
Try 0604.