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...

what is option explicit? what is the use of it?

Answer Posted / ritesh mahendrakar

You can declare variables with the Dim, Public or the
Private statement. Like this:

Dim myname
myname = "ritesh"

However, this method is not a good practice, because you
can misspell the variable name later in your script, and
that can cause strange results when your script is running.

If you misspell for example the "myname" variable
to "mynime", the script will automatically create a new
variable called "mynime". To prevent your script from doing
this, you can use the 'Option Explicit' statement. This
statement forces you to declare all your variables with the
dim, public or private statement.

Put the Option Explicit statement on the top of your
script. Like this:

Option Explicit
Dim myname
myname = "ritesh"

Is This Answer Correct ?    62 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is quicktest professional?

1012


What are the different recording modes and how do they work?

1072


Hi. I have completed B.TECH(CS) , But I will go to "SECURITY CONSOLE OPERATING" [C.C CAMERA abservation]. IF interviwer asks " Why you choose this job ?" What we will say? urgent.........................urgent...........

1903


What are the views available in qtp?

1017


How often were they executed?

2444


For example you are checking bit map check point before coming to the results. How can you say it is passed? Or failed? Anyways?

1009


What are the trigger events in qtp?

1102


How to use output values in qtp ?

993


what is key word driven frame work ? why it is called like that ? what is the diference between keyword driven and data driven frame work ?

1980


What are the ways you can synchronize?

1034


whare exactly we have to use functions and sub routain

2300


What are the steps involved in the recovery scenario wizard?

1005


How you can write contexts to text file in qtp?

1046


we add library file used in test via settings or through "ExecuteFile" command. when we implement framework do we make common library file and load the same for all the test cases execution?

2209


How to do the scripting. Is there any inbuilt functions in qtp as in qtp-s.

974