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

Answer Posted / 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       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the features of visual basic?

1641


Develop a parameterized action that accomplishes the following a. Launch a browser of users choice ( example : IE, chrome etc) b. Open up a search engine (Google, Bing etc) c. Perform a search d. Click a particular link depending on the user’s choice ( 1st , 2nd or third link)

1499


Mention what is select case statement?

624


Description.Create

2229


Hi this is Vinoth. I need a help on below mentioned question A combobox contains list of items assume as 5 I have to get each items Individually and I have to Export to datatable. Please help me on this. Thanks

1813






How do you declare a variable in vbscript?

718


what is diff between static and dynaic arrys?

1686


Why is it recommended to close the database connection every time after the work is completed?

596


hi all, i had a question, that how to find out hiding a coloumn in a table i had a table having the following column names NAME DESCRIPTION CREATED TIME CREATED USER if i right clicked on a NAME column it will displays a menu having the same column names in a list like NAME DESCRIPTION CREATED TIME CREATED USER with check boxes.if i unched any check box, that column name should not be appear in the main table column names could anyone please solve this problem?

1640


What methods are used to create text files and open text files in the vbscript language?

628


Which operator can be used to change the value of the operand or change the state of the condition?

673


Which function is used to perform string comparison?

666


Which in-built function related to an array joins substrings into one string in the vbscript language?

605


Hi All, I am facing one problem in QTP. There is link object in my application that exist in the Frame in mozilla firefox. Click event on that object is not working but once the frame is enabled/activated then click event works fine.But the frame does not have the activate property. This problem is coming in firefox only. Regards

2357


Explain the operator precedence in vb script?

739