Extra blank lines in code being added

I am getting back to coding with NSB after 2 year absence so I don’t know if this is maybe a feature or a preference.

When I first opened my older projects (NSB 7), all the code (Global and form) all had extra line blank line spaces. I went through and removed all the blank lines and didn’t think much about it. But now I’m getting them mysteriously coming back. I will open a project, and one form’s code (not everything), suddenly has extra blank lines again.

Just to clarify by extra lines see the example below. It’s annoying because it makes reading the code harder, and I don’t know why it keeps happening. I’m on a Mac OS 12.3.1 running NSB 8.5.7.1b1.

Function ABC()

a = 1

b = 1

c = 1

End Function

Function ABC()
a = 1
b = 1
c = 1
End Function

Any suggestions?
Thank you,
Malcolm

LineBreakRemoverTool.zip (11.6 KB)

It did that to all my projects too. I wrote this LineBreakRemoverTool. Paste your code in to the TextArea then it converts on pasting.

thanks for creating that, very helpful.
Hopefully they can fix whatever is causing it as it’s really annoying if it keeps happening.

The problem arises due to difference in how Windows and other operating systems store line breaks. Windows is CR NL, while the others are just NL. AppStudio expects just NL.

If you open a file in a Windows editor, it may convert the NL to CR NL, which results in what you are seeing.

Oh that probably explains why I had it happen in config.xml as I was using my Windows XML editor to edit it and then cut and pasted it back into NSB on my Mac and all the line breaks were gone so it was just one long line of code. So basically I should edit all code just on my Mac then.