markburse1
(Lurker)
2007-04-30 02:00 PM
systemdrive C:\ variable

Hello,

Our Kix login script uses C:\ in many places....I need to change this to a variable that finds where the "%systemdrive%" is. Our C:\ on Citrix servers has been re-mapped to the K:\, and we only use one login script.

Mark


Howard Bullock
(KiX Supporter)
2007-04-30 02:13 PM
Re: systemdrive C:\ variable

check out the results of the following script. Let us know if you have any other questions.
 Code:
break on

? ExpandEnvironmentVars(%systemdrive%)
? ExpandEnvironmentVars("%systemdrive%")
? "Just var = " + %systemdrive%
 


markburse1
(Lurker)
2007-04-30 03:32 PM
Re: systemdrive C:\ variable

Thanks

Current line = if exist "c:\opra tools\gandalf\*.*" Goto GandalfUpdate

Example new line? = "%systemdrive%\opra tools\gandalf\*.*" Goto GandalfUpdate

Is there a way to test locally by running Kix on my pc without changing .BAT file?


Howard Bullock
(KiX Supporter)
2007-04-30 04:51 PM
Re: systemdrive C:\ variable

Unrelated suggestion: Try to restruction your code to avoid the use of GOTO.

Creat a test script on your computer saving it to some specified directory. Open a CMD window and change to that directory. Place Kix32.exe on your computer, possibly in this directory where your script resides.

Execute Kix32.exe test.kix

You will need to write the necessary checking or logging code to verify that the text script did what you wanted.