Regular Expression for below pattren

Hi
Sorry to bother about silly question, but i am new and i need to replace in below string using Regular Expression:

<img src=" Here it could be anything including String,Number,".","_" and “-” width=“338” height=“89”>

But pattern will be always like this i.e. it will start with < and ends with >.
Any help highly appreciated.

2 Likes

Buddy what you would like to replace here with this string

just set it blank, i mean replace with “”

1 Like

Buddy do you want to replace entirely from SRC = to Width =, i mean the highlighted one
" Here it could be anything including String,Number,".","_" and “-”
Just to clarify

Sorry for creating confusion:
" <img src=" Here it could be anything including String,Number,".","_" and “-” width=“338” height=“89”>"
This entire text that is start from “<” and ends with “>” i want to replace and it could have string, integer,.,_,- between < and >.

1 Like

use this expression buddy @gupta.rak1984

<.*?>

like this

Thanks for help, It worked.
it would be great if you can explain logic or any link where i can get clarification.
Also can you please guide me any site where i can learn VB.net for Uipath specially String manipulation.

1 Like

Thats amazing buddy @gupta.rak1984

here you can check for regex operation

Kindly close this thread with solution marked that could help others buddy @gupta.rak1984

Cheers

@gupta.rak1984,

Yes. I can understand your question. Please use this logic.|

System.Text.RegularExpressions.Regex(myString,"<.*?>")) Or

System.Text.RegularExpressions.Regex.Match(myString,"<.*?>")) Or
System.Text.RegularExpressions.Regex.Replace(myString,"<.*?>",replaceString))

Thanks,
Arunachalam.

2 Likes

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.