Below is the code which to remove the string.
Dim Commune As String = "Chaom Choa"
Dim District As String = "Porthisen Chey"
Dim Province As String = "Phnom Penh"
Dim Address As String
Address = "I live in " & Commune & ", " & District & ", " & Province
Address = Address.Remove(31, District.Length)
MsgBox(Address)
In this sample, the message will show "I live in Chaom Choa, Phnom Penh" because it removes district string"Porthisen Chey" from whole string.
Wednesday, May 21, 2014
How to remove a string(VB.Net)
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment