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


YourString = ;abc;efg;xyz


Mark as solution if this helps


1 Like

@Mahalakshmi - you can try
if condition - YourStringVar.StartsWith(";")
true -
YourStringVar = YourStringVar.Substring(1)

1 Like

Making @ksrinu070184 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