MSFN Forum: Variable woes - MSFN Forum

Jump to content


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Variable woes Create a variable from a variable Rate Topic: -----

#1 User is offline   benners 

  • Senior Member
  • PipPipPipPip
  • Group: Members
  • Posts: 692
  • Joined: 29-December 03

Posted 10 August 2005 - 04:11 PM

I am having problems trying to create variables that contain variables and text.

I am trying to create a variable #APP# that points to my applications folder, it is made up from the #SOURCEDRIVE# variable and Applications
<APP>#SOURCEDRIVE#\Applications</APP>

to cut down on the old Carpel Tunnel :D , the trouble is whilst it works when running in Windows it does not work running from cmdlines or GUIRunOnce. The same is said for other variables that are created the same way, i.e #IMG# created from #XPLODE# and images
<IMG>#XPLODE#\images</IMG>

the variables inside the variables are not expanded they are used as a string, so the log file reports

Quote

Install log: Running: '#SOURCEDRIVE#\Applications\alcohol\setup.exe /verysilent'
Error during execution: File not found..

Is there a way to accomplish what I want to do?, xml and logfiles attached.

Attached File(s)




#2 User is offline   Wraith 

  • Dr. Nick
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,256
  • Joined: 01-January 04

Posted 12 August 2005 - 07:57 PM

I'll look into it in the near future - been extremely busy lately.
In the meantime, you might want to look up XML entities, they should be able to solve your problem.

#3 User is offline   benners 

  • Senior Member
  • PipPipPipPip
  • Group: Members
  • Posts: 692
  • Joined: 29-December 03

Posted 13 August 2005 - 11:26 PM

Thanx Wraith, who knew I was using entities already with the &amp;.

How would adding entities differ from adding elements under xplodes environment tag, it seems to me like the #SOURCEDRIVE# variable is not being expanded when it is part of a string?.

Thanx again for the help and I hope you get some chill time soon

#4 User is offline   Wraith 

  • Dr. Nick
  • PipPipPipPipPipPip
  • Group: Members
  • Posts: 1,256
  • Joined: 01-January 04

Posted 13 August 2005 - 11:42 PM

Well, the XML parser works through the entities before the environment variables.... so if you have an entity called &blah; pointing to "#SOURCEDRIVE#\Install", then it will definitely be used before any other environment variables are passed.

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2013 msfn.org
Privacy Policy