PhilB
Posts: 95
Joined: Fri Jul 06, 2007 4:13 pm

Text File Update woes

Using AI 11.0 on win7 I am trying to use text file update to append/create overwriting the file if it already exists.
The hoped for content is something like this (a bit simplified):

Plugins =
{
Plugin =
{
Filename = "[WindowsVolume]filename.dll"
Configuration = test="test.cfg";12345
}
}

What I end up with is this:
Plugins =

Plugin =
{
Filename = "C:\filename.dll"
Configuration = test="test.cfg";12345

}

i.e. missing a couple of curly brackets!

If I omit the windows installer property from my content then everything works as expected, i.e. all 4 curly brackets are present.

Any ideas how I can get round what looks like a bug to me! My real file uses [APPDIR], so hard coding c:\ is not a solution!

Phil
PhilB
Posts: 95
Joined: Fri Jul 06, 2007 4:13 pm

Re: Text File Update woes

Answering my own question!

It would appear that I have to use [\}] instead of just } and so on.

:idea: It might be nice if this sort of thing was explicitly mentioned in the documentation.
Dan
Posts: 4530
Joined: Wed Apr 24, 2013 3:51 pm

Re: Text File Update woes

Hi Phil,

I'm glad you got this working by yourself.
It would appear that I have to use [\}] instead of just } and so on.
It might be nice if this sort of thing was explicitly mentioned in the documentation.
Thank you for sharing this with us. Since the content field of the text file update is of Formatted Type, the rules are applied too:
  • [\x] is replaced by the character x; for example, to include a left bracket ([), use [\[]
Maybe, we should also add o note for the text file update article.

If you have other questions, please let us know.

Best regards,
Dan
Dan Ghiorghita - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”