Home > Net >  Remove digits/numbers from a string
Remove digits/numbers from a string

Time:10-01

I am working on one task (related to vb.net) where I need to get only text but no digits in it.

For example I am getting the value "0196 CARPORT" but instead of this I need to get "CARPORT" to make my condition satisfied.

Could someone please help me in achieving this . Thanks in Advance!

CodePudding user response:

You can use Regex to remove all numbers like this.

Regex.Replace(theString, "\d", String.Empty).Trim()

  • Related