Removing the first string occurrence in a string

My String is - ;abc;efg;xyz
Me expected output is - abc;efg;xyz

How do I remove the first occurring semicolon

@Mahalakshmi

YourString = ;abc;efg;xyz

YourString.SubString(1,Yourstring.length-1)

Mark as solution if this helps

Thanks

3 Likes

@Mahalakshmi - you can try
if condition - YourStringVar.StartsWith(“;”)
true -
YourStringVar = YourStringVar.Substring(1)
false
ignore

1 Like

@Mahalakshmi
Making @Srini84 response dynamic

YouString = ;abc;efg;xyz
CharToRemove = ;
YouString.SubString(YourString.FirstIndexOf(CharToRemove) + 1,youstring.length)

This will help you remove the first occurence of char as mentioned in Title

1 Like

strText is your String use an assign:
left side: strText
right side:
IF(strText(0).Equals(";"c), strText.Substring(1),strText)

1 Like