No igconfig.xml created in %APPDATA% when starting ImageGlass with igconfig.admin.xml and igconfig.default.xml

146 views
Skip to first unread message

p.ma...@gmail.com

unread,
Feb 19, 2021, 7:27:28 AM2/19/21
to ImageGlass Community
Hi!

Trying to set up an installation of ImageGlass that can be deployed to our users. I've put an igconfig.default.xml and 
igconfig.admin.xml in the Start-folder (C:\Program Files\ImageGlass). igconfig.default.xml contains all the normal setting after running the first launch wizard, including Swedish Language support. igconfig.admin.xml only contains that Autoupdate = 0. However, when I start ImageGlass no %APPDATA%\ImageGlass folder is created and naturally no igconfig.xml either. However, if I manually create the %APPDATA%\ImageGlass folder then everything seems to work fine. The igconfig.xml is created and all setting except AutoUpdate can be changed. But why isn't it the folder and file created at first launch?


Hello!

Before posting, you can check if your questions are posted or answered.

This page is for generic questions, if you want to report a bug or 
request new features, please open a topic at 

Thank you for using ImageGlass!
Phap

p.ma...@gmail.com

unread,
Feb 23, 2021, 7:28:12 AM2/23/21
to ImageGlass Community
Anyone seen this before?

Kevin Routley

unread,
Feb 23, 2021, 3:19:16 PM2/23/21
to ImageGlass Community
Reading the docs [https://imageglass.org/docs/app-configs] I suspect IG is not creating %APPDATA%\ImageGlass because IG has write permission for start-folder.

To quote:

> In portable mode, Config dir is also Startup dir. If ImageGlass does not have write permission to Startup > dir, it will use %AppData%\ImageGlass\ instead.

I'm assuming you're in portable mode [as you're not giving your uses an installation file] and IG will use "C:\program files\ImageGlass" for igconfig.xml. Try modifying C:\Program Files\ImageGlass so that IG cannot write to it, and maybe then IG will use %APPDATA% by preference.

p.ma...@gmail.com

unread,
Feb 25, 2021, 2:19:32 AM2/25/21
to ImageGlass Community
Hi, thanks for you reply. I installed ImageGlass using the MSI. Then copied the two XML files to the start dir: C:\Program Files\imageGlass. 

lifeatt...@gmail.com

unread,
Feb 26, 2021, 2:25:39 PM2/26/21
to ImageGlass Community
I had to trace the code to be certain I wasn't making a misstatement.

The code logic is as I said: if IG can write to the folder where ImageGlass.exe resides, then igconfig.xml will be written there. This is true whether IG is installed or "portable".

If, on the user's system, you want igconfig.xml to be written to their %AppData% folder, then you have to deploy the IG folder so the user's account does not have Write privileges for the deploy folder. I.e. if you deploy IG to "C:\program files\ImageGlass" on the user's system, then the user account must not have Write access to "C:\program files\ImageGlass".

I know other folks have deployed IG to multiple users, I wonder if we can get them to contribute?
Reply all
Reply to author
Forward
0 new messages