How to covert a String to an integer?
Answers were Sorted based on User's Feedback
Answer / venkateshwarlu
using cint function
dim var1, var2
var1=10.89
var2=cint(var1)
msgbox var2
will give integer value : 10
Is This Answer Correct ? | 11 Yes | 5 No |
Answer / vulani
Here's the shortest way to do it Gents:
string mystr ("1204");
int myint;
stringstream(mystr) >> myint;
Is This Answer Correct ? | 1 Yes | 1 No |
Answer / varun bisaria
CInt()---> a conversion function available.
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / bfakruddin
dim str,num
str="Hello"
num=100
cstr=cint(str) ' It converts string into integer
msgbox cstr
cint=cstr(num) ' It converts Integer into string
msgbox cint
Is This Answer Correct ? | 8 Yes | 14 No |
Answer / raja83
you can use cint function
cint(10) will convert integer 1
Is This Answer Correct ? | 4 Yes | 11 No |
What are default add-ins in qtp?
In Remote acess server how u run a test?
Explain QTP testing process?
Object Repositories types, which & when to use?
How does QTP identifies the object in the application?
1)what is the Exact Meaning of Environment Variables? 2)what is Compile Module in QTP? what exactly it contains Functions or Actions?
what is regular expression how will you implement it?
str="QTP AUTOMATION TESTING" here how many T are there in the str finally i want to display the T
If an application name is changing frequently i.e while recording it has name “Window1” and then while running its “Windows2” in this case how does QTP handle?
how to validate email?email ie correct or not ?with below conditions. 1)before @(symbol) only alphbates and min 4 char to max 15 chars. 2)before @(symbol) only alphabates dont use ant special chars or numarics 3) after @(symbol) only one dot(.)symbol for ex:abc@gmail.com it is valid email or not based above conditons
what does it mean when a check point is in red color? what do u do?
Hi ,Can any one pleas explain how to test splash objects using QTP?