It simply doesn't work...
Reading goes ok, when writing is ignored. File access rights are ok, written values are ok, no idea what is the reason...
Edit INI File $TARGETDIR$\\defaultSettings\\JStationrc, [Database] Asset DB Host=$DB_SERVER$
Eny idea?
regards
Jarek
Edit INI file - write fails
-
- Posts: 3452
- Joined: Thu Dec 22, 2005 7:17 pm
- Contact:
Are you checking for whether this works or not after Apply Install?
Michael Nesmith
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
I need to read ini file before installation and modify it after install. So I attached this file twice - to Creatives, for reading before and to Files for modification after install. I'm modifying this file after 'Apply Install' just before Finish.
One question about INI files - what will happen if I repeat the section on file begining (so it will be defined twice). Which definition will be ignored? First or second? I think about using 'Write to file' command.
regards
Jarek
One question about INI files - what will happen if I repeat the section on file begining (so it will be defined twice). Which definition will be ignored? First or second? I think about using 'Write to file' command.
regards
Jarek
-
- Posts: 3452
- Joined: Thu Dec 22, 2005 7:17 pm
- Contact:
You will need to call Apply Install again - there was a very similar post in this forum, that explains the logic behind this (the post was about registry entries not being created) - please try to find that one.
Michael Nesmith
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
In my case, I was definitely calling it after Apply Patch. Everything is after the "TO-DO: Insert any additional install commands here" comment, in the "else" part of the If Variable BUILDMODE Equals PATCH statement.
In my case I was able to work around it using "Write to Text File", but it is still worrisome.
Eric
In my case I was able to work around it using "Write to Text File", but it is still worrisome.
Eric
-
- Posts: 3452
- Joined: Thu Dec 22, 2005 7:17 pm
- Contact:
Eric, reading this whitepaper will assuage your worries: www.installaware.com/msicode_scripting_technology.pdf
Michael Nesmith
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
Michael, thank you for the additional info. Placing MSI commands before Apply Install does indeed work.
An additional, related question: does it matter where non-MSI commands go? Should they specifically go after "Apply Install", for example? If placed before Apply Install, does InstallAware automatically pull them out and execute them outside the MSI?
Thanks,
Eric
An additional, related question: does it matter where non-MSI commands go? Should they specifically go after "Apply Install", for example? If placed before Apply Install, does InstallAware automatically pull them out and execute them outside the MSI?
Thanks,
Eric
-
- Posts: 3452
- Joined: Thu Dec 22, 2005 7:17 pm
- Contact:
For full answers to these questions, please read:
www.installaware.com/msicode_scripting_technology.pdf
This will be well worth your investment in time if you will be working with InstallAware in any serious capacity.
The short answers to your question is: It does matter where non-MSI commands go - they execute immediately. So in some cases you want to place them before Apply Install, in other cases after Apply Install. All depends on your setup logic. The same goes for MSI commands too, actually. You can call Apply Install multiple times, for instance, if you need to.
www.installaware.com/msicode_scripting_technology.pdf
This will be well worth your investment in time if you will be working with InstallAware in any serious capacity.
The short answers to your question is: It does matter where non-MSI commands go - they execute immediately. So in some cases you want to place them before Apply Install, in other cases after Apply Install. All depends on your setup logic. The same goes for MSI commands too, actually. You can call Apply Install multiple times, for instance, if you need to.
Michael Nesmith
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
InstallAware
Home of The Next Generation MSI Installer
Get your free copy today - http://www.installaware.com/
Who is online
Users browsing this forum: No registered users and 40 guests