Forum Discussion

geethwind's avatar
geethwind
Contributor
13 years ago

retrieving local Project variables in test complete

i am trying to create the project level variables  by using Project.variables.Addvariable method.. and these are set to local values.. how can i set them to defaultvalues so that i can retreive by using  "GetVariableDefaultValue"

'



my code looks like



strName = "BROWSER "

project.Variables.AddVariable strName, "String"



project.Variables.BROWSER = "iexplore"



varVal = Project.Variables.GetVariableDefaultValue(""&strName&"")



varVal returns empty always as AddVariable sets to local value instead Default, is there any way i can retrieve local values / set tom default values?



thanks,


.Variables.BROWSER = "iexplore".Variables.GetVariableDefaultValue(""&strName&"")varVal returns empty always as AddVariable sets to local value instead Default, is there any way i can retrieve local values / set tom default values?thanks,

1 Reply


  • Hello Geeth,





    Currently, a variable default value cannot be modified from script. We have a suggestion to implement this ability in our database, and your request has increased its rating. Thank you.





    The workaround is to use the Variables page of the project editor.