just a simple tool which you may or may not find of some use. All it does is take the current source you have open in the PB IDE and generates the corresponding assembly code and loads it into notepad etc.
Compile to "commentedASM.exe" :
Code: Select all
file$=ProgramParameter(0) dir$ = GetPathPart(file$) DeleteFile(dir$+"PureBasic.asm") If file$ And FileSize(file$)>0 Compiler = RunProgram(#PB_Compiler_Home+"\Compilers\pbcompiler", Chr(34)+file$+Chr(34)+" /commented", dir$, #PB_Program_Hide|#PB_Program_Wait) dir$+"PureBasic.asm" If Compiler And FileSize(dir$)>=0 RunProgram("notepad.exe", dir$,"") Else MessageRequester("Error!", "There was an error creating the assembly code file.") EndIf EndIf
(Make sure that you select the name of the commentedASM.exe (with full path) in the CommandLine option.
In the 'Arguments:' control enter "%TEMPFILE" with the quotes. Select the 'Run Hidden' checkbox.)
**EDIT : change the command RunProgram("notepad.exe", dir$,"") to simply RunProgram(dir$) if your system is set up to deal directly with .asm files etc.