How to use substring in this example?


#1

Hello everyone,

I have a text with multiple lines. I just want to delete the first line and to obtain the rest of the text with no blank spaces neither at the beginning nor at the end.

Example of the text:
image

I want to get this text:
image

NOT LIKE THIS:
image

To sum up: I want to delete the first line of a text and to obtain the rest of the text without blank spaces.
Regards!


#2

Hi @pal1910, if you use “YourString”.Trim, you will be able to get rid of those blank spaces.


#3

@pal1910

In your case you need to get the 2nd line content and replace with the first line, once after replacing you can remove the 2nd line.
So ‘First line’ will be replaced with ‘This is’ .


#4

Please, could you be more specific? Thanks a bunch


#5

variable A = your string
A =A.replace(“First line”,"")
A=A.trim

i hope it works


#6

mid(mystr,instr(1,mystr,vblf)).Replace(vblf,"")