Thread Rating:
  • 2 Vote(s) - 4.5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
QTP script to read QTP filename
#1
Solved: 10 Years, 8 Months, 4 Weeks ago
Hello,
I am trying to add a piece of code to our framework where we are trying read the name of the file thats being run.For example:If I have a script 'TestCase1'.I need to write a piece of VbScript code which reads reads the filename and stores in a variable.The code is written within the file itself.

Hari
Reply
#2
Solved: 10 Years, 8 Months, 4 Weeks ago
You can use Environment("TestName") to get the name of file.

Please correct, if wrong.

Regards,
Sankalp
Reply
#3
Solved: 10 Years, 8 Months, 4 Weeks ago
Thanks Sankalp That was easy!
Reply
#4
Solved: 10 Years, 8 Months, 4 Weeks ago
U r welcome.. Smile
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Wink How to read text in command prompt using QTP Sourabh146 1 6,351 11-30-2013, 11:02 AM
Last Post: ravi.gajul
  Read text from text file and save it into a variable in qtp arpan 3 12,096 06-19-2013, 08:34 PM
Last Post: arpan
  How to read a unix flat file from a unix server using QTP vinayjames.b05 3 9,304 06-18-2012, 11:12 PM
Last Post: gunaseakaran
  Run QTP script on system without QTP IDE nacchio 3 10,828 10-12-2011, 06:47 PM
Last Post: nacchio
  Script to read a XML file Anand 4 21,616 05-30-2011, 12:27 PM
Last Post: Anand

Forum Jump:


Users browsing this thread: 1 Guest(s)