Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Accessing Environment variable value in Library file
#1
Not Solved
Hi All,

I have a environment variable defined in the external Environment.vbs file. And I am trying to access its value and assign to a variable in library file. and then using the variable in library in action. I'm getting an error saying the couldn't able to find the environment variable.

I have the below file and content

------------------------------------------------------
Environment.vbs
------------------------------------------------------
Environment.Value("URL") = "www.google.com"
------------------------------------------------------


-------------------------------------------------------
MyLibrary.qfl
-------------------------------------------------------
strURL = Environment.Value("URL")
-------------------------------------------------------

-------------------------------------------------------
MyAction
-------------------------------------------------------
SystemUtil.Run strURL
-------------------------------------------------------

Thanks and Regards:
Vishruth
Reply
#2
Not Solved
Hi,
You better use a variable public instead of an environment variable, I have worked very well to work with files .vbs
greetings.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Not able to get the list of items in Delphi Combobox Environment Object Raj Aryan Singh 3 1,956 02-04-2020, 12:32 AM
Last Post: Raj Aryan Singh
  how to get relative path by using testdir environment variable Sathyaprasad 1 1,779 11-30-2017, 02:21 AM
Last Post: supputuri
  environment variable path for qc automation2012 0 2,632 01-18-2015, 08:18 AM
Last Post: automation2012
  Select does not work together with Environment.Value qtped 7 3,817 02-14-2014, 12:46 PM
Last Post: supputuri
  Using QTP features in Function library TurtleRock 0 1,650 01-30-2014, 06:02 PM
Last Post: TurtleRock

Forum Jump:


Users browsing this thread: 1 Guest(s)