Multiple command in the same line

Just starting out? Need help? Post your questions and find answers here.
reisve
User
User
Posts: 86
Joined: Sat Nov 08, 2008 4:52 pm
Location: Luanda, Angola

Multiple command in the same line

Post by reisve »

I think I've seen code like this in examples code

Code: Select all

    If b = 0: ErrorHandler()
is this a valid code? It gives me an error saying I'm missing the EndIf

and BTW how do I split a long code line? equivalent to VB &_
Seldon
Enthusiast
Enthusiast
Posts: 405
Joined: Fri Aug 22, 2003 7:12 am
Location: Italia

Post by Seldon »

Code: Select all

If b = 0 : ErrorHandler() : EndIf
It is not possible to split a long line with the PB Editor, though it would be a very nice option, especially when you have to deal with long SQL queries.
reisve
User
User
Posts: 86
Joined: Sat Nov 08, 2008 4:52 pm
Location: Luanda, Angola

Post by reisve »

Thanks

Maybe the long line split should go to the whish list...
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6172
Joined: Sat May 17, 2003 11:31 am
Contact:

Post by blueznl »

Ah, the legendary multi-line request :-)

Do a search on the forum, it's a famous hot topic :-)
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB - upgrade incoming...)
( The path to enlightenment and the PureBasic Survival Guide right here... )
User avatar
graves
Enthusiast
Enthusiast
Posts: 160
Joined: Wed Oct 03, 2007 2:38 pm
Location: To the deal with a pepper

Post by graves »

Ah, the legendary multi-line request
I'm not able to understand the Fred's reasons for not including it.

I've developped a Pre-Compiler to add some special treatments in my programs, and also I've included this feature very very easily.
Why Fred doesn't? :?: :?:
aaron
Enthusiast
Enthusiast
Posts: 267
Joined: Mon Apr 19, 2004 3:04 am
Location: Canada
Contact:

Post by aaron »

graves wrote:Why Fred doesn't? :?: :?:
There are times when I could have used a way to split long lines into multi-lines, but I think that we have to admit that this feature is a long way down the list of goodies that we need. :D

I'm still waiting for a do_game(asteroids) function. :lol:
reisve
User
User
Posts: 86
Joined: Sat Nov 08, 2008 4:52 pm
Location: Luanda, Angola

Post by reisve »

I made a post in wishlist... just in case
As Seldon said, it is very usefull on those long SQL Queries, and not only. Using APIs with a huge list of arguments, you can easly get lost...
User avatar
pdwyer
Addict
Addict
Posts: 2813
Joined: Tue May 08, 2007 1:27 pm
Location: Chiba, Japan

Post by pdwyer »

+1 :lol:

just in case it's a new election, different from last time :wink:
Paul Dwyer

“In nature, it’s not the strongest nor the most intelligent who survives. It’s the most adaptable to change” - Charles Darwin
“If you can't explain it to a six-year old you really don't understand it yourself.” - Albert Einstein
User avatar
Kwai chang caine
Always Here
Always Here
Posts: 5502
Joined: Sun Nov 05, 2006 11:42 pm
Location: Lyon - France

Post by Kwai chang caine »

ImageThe happiness is a road...
Not a destination
User avatar
pdwyer
Addict
Addict
Posts: 2813
Joined: Tue May 08, 2007 1:27 pm
Location: Chiba, Japan

Post by pdwyer »

the lord works in mysterious ways :D
Paul Dwyer

“In nature, it’s not the strongest nor the most intelligent who survives. It’s the most adaptable to change” - Charles Darwin
“If you can't explain it to a six-year old you really don't understand it yourself.” - Albert Einstein
User avatar
Kwai chang caine
Always Here
Always Here
Posts: 5502
Joined: Sun Nov 05, 2006 11:42 pm
Location: Lyon - France

Post by Kwai chang caine »

the lord works in mysterious ways
:lol: :lol:
ImageThe happiness is a road...
Not a destination
reisve
User
User
Posts: 86
Joined: Sat Nov 08, 2008 4:52 pm
Location: Luanda, Angola

Post by reisve »

And no posts here from anyone from the development team...
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Post by Kaeru Gaman »

I think they are busy enough caring for serious problems... :o
oh... and have a nice day.
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Post by PB »

It can't be that hard to do.
I compile using 5.31 (x86) on Win 7 Ultimate (64-bit).
"PureBasic won't be object oriented, period" - Fred.
User avatar
Kaeru Gaman
Addict
Addict
Posts: 4826
Joined: Sun Mar 19, 2006 1:57 pm
Location: Germany

Post by Kaeru Gaman »

it would mean that freak fully concentrates on this change of the IDE and leaves what ever he does aside for this time.
so this (not very serious) task will steal away freaks manpower from the main tasks for two or four weeks.

... if this is enough to make it stable.
I rather do without line merging than sitting on an unstable IDE.

and there are serious tasks in the main project, and there are more points than this one on the to-do-list for the IDE...

so what?
they made a great jump this version: actual OGRE and x64
and not all features are 100% stable right now.

... so why waste manpower with some nice-to-have-task that is easily replaced by one of a dozen avaliable plugins?
oh... and have a nice day.
Post Reply