incendio Well-Known Member Licensed User Longtime User Apr 23, 2014 #1 Hi guys, Sorry for noob question, what is the syntax to break long string into multiple line ? For ex : B4X: Str = "this is a long string that needs to break into multiple line" I want to write in code : B4X: Str = "this is a long string that needs " & "to break into multiple line" Tried to search, but didn't find.
Hi guys, Sorry for noob question, what is the syntax to break long string into multiple line ? For ex : B4X: Str = "this is a long string that needs to break into multiple line" I want to write in code : B4X: Str = "this is a long string that needs " & "to break into multiple line" Tried to search, but didn't find.
Erel B4X founder Staff member Licensed User Longtime User Apr 23, 2014 #2 Use underscore: B4X: Str = "this is a long string that needs " _ & "to break into multiple line" Upvote 0
incendio Well-Known Member Licensed User Longtime User Apr 23, 2014 #3 Thanks Erel, I need to remind my self that there is a space before _! Without space it raised Error. Upvote 0
Dave O Well-Known Member Licensed User Longtime User May 25, 2015 #4 It would be handy to add a Break Line to the Edit menu, where it was broken at the cursor and added the underscore. Would make this more visible and easier to learn. Upvote 0
It would be handy to add a Break Line to the Edit menu, where it was broken at the cursor and added the underscore. Would make this more visible and easier to learn.
Erel B4X founder Staff member Licensed User Longtime User May 26, 2015 #5 The correct way to write multiline strings is: B4X: Dim str As String = $"This is a long sentence that spans multiple lines."$ https://www.b4x.com/android/forum/threads/50135/#content Upvote 0
The correct way to write multiline strings is: B4X: Dim str As String = $"This is a long sentence that spans multiple lines."$ https://www.b4x.com/android/forum/threads/50135/#content