Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

While writing script using For Next Statement in QTP, I try
defining the variable in Lib File I am getting syntax error
whereas if I use the variable in script file, the script
works fine. Can anyone help me in finding the reason behind
this?.
E:g

Dim intStartRow (Define in Lib File----- say abc.vbs)

Dim intRow (If I define this variable in Lib file I am
getting Syntax error where as if I define in the script
file ---- say xyz.mts the script works fine)

IntStartRow=2

For intRow = intStartRow to xlWrksht.UsedRange.Rows.Count

‘Some Code here

Next

Answer Posted / jay prakash

should be some simple error in ur declaration. Nothing big
in this.

Do as below:

In Lib file, MyLib.vbs:
Dim i
i=10

In Script File
msgbox i

Include the lib file and run the script. No error.

If you can share the script i may be able to help u in
identification of your error.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the XML file architecture ?

1948


How to delete an object from the object repository?

1037


Call to copy of an action and call to existing action… i know the diff but in real project how to use..? i want live scenario.pls help me..

1719


hi guys, pls tell me for testing institution training hub, hitech city is best or not?

1771


What are the different types of functions available in qtp and explain ?

959


what is ODC and GDC?

7807


What are the advantages of parameterization ?

1001


What are the data types in qtp?

1042


What are the key points to create a framework in QTP for oracle forms?

2199


Dear All , For UFT 12.02 which version QC or ALM will support ? Thanks Balaji

1329


What is the difference between call to existing action and copy of an action?

1038


What is difference between design time and run time data table?

1076


What we are looking for is to load properties of object dynamically as for our application the global repository will pretty huge. It will be really helpful to us if something similar to following functions of Winrunner is available in QTP. #Define descriptor auto strDesc; #set property in the descriptor Gui_desc_set_attr(strDesc,?Class?,?Edit?); --- put other properties #Add Edit box to GUI Map Gui_add(? ?,strWindowName,strEditboxName,strDesc);

3954


How to analyzing test results using quicktest professional (qtp)?

989


How to use reporter.report event in qtp ?

972