How to return only alpha bate string from an string str =
"bibhu@#$%&das&*)(SUndar"

Answers were Sorted based on User's Feedback



How to return only alpha bate string from an string str = "bibhu@#$%&das&*)(SUndar&quo..

Answer / satishraja

str ="bibhu@#$%&das&*)(SUndar"
L=len(str)
For i=1 to l
x=left((right(str,l-i+1)),1)
If ASC(ucase(x))>=65 and ASC(ucase(x))<=90 then
Print x
End If
Next

Is This Answer Correct ?    0 Yes 0 No

How to return only alpha bate string from an string str = "bibhu@#$%&das&*)(SUndar&quo..

Answer / usha

str="bibhu@#$%&das&*)(SUndar"

Set r = new regexp
r.pattern="[A-Z]"
r.global=true
r.ignorecase=true
Set a =r.execute(str)
msgbox a.count
For each t in a
msgbox t
Next

Is This Answer Correct ?    0 Yes 0 No

How to return only alpha bate string from an string str = "bibhu@#$%&das&*)(SUndar&quo..

Answer / pankaja yathindrakumar

'How to return only alphabate string from an string str = "bibhu@#$%&das&*)(SUndar"

str="bibhu@#$%&das&*)(SUndar"
for i=1 to len(str)
x=mid(str,i,1)
if Asc(x)>=Asc("A") And Asc(x)<=Asc("z") then
t=t&x
End If
Next
Msgbox t

Is This Answer Correct ?    0 Yes 0 No

How to return only alpha bate string from an string str = "bibhu@#$%&das&*)(SUndar&quo..

Answer / indrani

str="bibhu@#$%&das&*)(SUndar"

Set r = new regexp
r.pattern="[A-Z]"
r.global=true
r.ignorecase=true
Set a =r.execute(str)
msgbox a.count
For each t in a
s1=s1+t
Next
msgbox s1

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More VB Script Interview Questions

what is the function to get the ascii value of the character?

6 Answers   Netxcell, Oracle,


how to store charecters of HARIBABU Using arrays

4 Answers   Cap Gemini,


hi what is called GUI in QTP 8.2 and how can we test the apllication using GUI?

0 Answers  


Explain about scrrun.dll in vbscript?

0 Answers  


When to use function procedures and what are its characteristics?

0 Answers  


Explain about arrays in vb script?

0 Answers  


Could Anybody tell me VBScript for Check if a given number is Prime number-Don't use any Built- in Functions Boolean/int is Prime(int number).. Thanks in advance.

12 Answers   Amazon, Pyroferus,


HOw we can apply web service checkpoint in QTP 9.5? I tried it out with net connection also. But not getting success.

0 Answers  


Like OPTION EXPLICIT statement what are the other statements used in vbscript and their usage. Please post me all the statements please.

0 Answers   Accenture,


Please Example programms on vbscript 1)writing functions and calling functions

2 Answers   CIL, TCS,


How to create a cookie using vbscript?

0 Answers  


Explain the support of asp for vb script functionality?

0 Answers  


Categories