CommandLine$()

Blitz3D Forums/Blitz3D Programming/CommandLine$()

xmlspy(Posted 2006) [#1]
Ok, this is bugging the hell out of me... When I load a mesh via commandline on the blitz ide it works fine... then I drag and drop from explorer to the exe and it gives me a mav, anyone one know why this is?

Also, it seems that the program is not doing execfile from the compiled main.exe It only works when it's being run from the blitz ide.


GfK(Posted 2006) [#2]
Put some code in to output Commandline$() to a text file.

Also, it seems that the program is not doing execfile from the compiled main.exe It only works when it's being run from the blitz ide.
When you run code in the IDE, all it does is compile a temporary EXE and runs it.

Probably a path issue or something.


xmlspy(Posted 2006) [#3]
Graphics 320, 240, 0, 3
AppTitle "Media Viewer"
Global file$

cdir$ = CurrentDir()
file$=CommandLine()
file$=Replace(file,Chr(34),"")
file$=Trim(file$)
If file$="" End

fo = WriteFile("debug.txt")
	WriteLine fo, cdir$
	WriteLine fo, file$
	WriteLine fo, FileType(file$)
CloseFile(fo)

The stupid program would open up and close as soon as it could, then it would write the debug.txt to where the file$ dir was... instead of where the program is/was.


xmlspy(Posted 2006) [#4]
Got it working fine with the use of SystemProperty("appdir")


xmlspy(Posted 2006) [#5]
50% scaled down image... and the dang thing works pretty good and the simple interface with the mouse and keyboard kicks a. I run at 1400x900, with my new wide HD display.



jfk EO-11110(Posted 2006) [#6]
For some reason there was a limit for image sizes - they should not be bigger than the desktop resolution. I think it was a Directx limitation thing.


xmlspy(Posted 2006) [#7]
What the heck are you talking about? probably wrote on the wrong topic...