View Single Post
Old 05-25-2007   #1 (permalink)
Frank


 
 

returning values to original script

Hi,

I have a script called menu.ps1 which calls another PS script,
getvalues.ps1. In getvalues.ps1, I do some console interaction with the
user. Depending on the interaction, I need to return a value back to the
original menu.ps1 script. I tried to do a return "$value" but that didn't
work. What did work was to define a global variable via: $global:testvar.
Is that the best way to return a value back to the original script? I rather
not use a global variable if I didn't to.

Thanks,


My System SpecsSystem Spec