[Implemented] ProgramParameter(0)

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

[Implemented] ProgramParameter(0)

Post by BackupUser »

Restored from previous forum. Originally posted by pbdep.


Hello Fred,

I know ProgramParameter() will return one after one, but thats
a little anoying :wink:

Also Args(0) should better return the program name!
(Can be found in the Exe and Com stack between? 0000 - 0800 i think?)

Anyway Could you enhance ProgramParameter by ->

Result = ProgramParameter() ; return the length of Args
Result = ProgramParameter(0) ; return the Filename
Result = ProgramParameter(n) ; return the args ..n


The above is better then pushing yourself into WindowsAPI calls
and Linux executes to get your program name while its simply
inside the Binary :wink:

Regards,
Norman.
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by pbdep.


Correction:
Its ot inside the binary, its located in
the stack (Fileinfo) area after execution.

Norman.
BackupUser
PureBasic Guru
PureBasic Guru
Posts: 16777133
Joined: Tue Apr 22, 2003 7:42 pm

Post by BackupUser »

Restored from previous forum. Originally posted by fred.

I will better add a ProgramName() command, as ProgramParameter() has nothing to do with the name :).

Fred - AlphaSND
Post Reply