flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
Tomasz Grysztar 29 May 2017, 07:59
Try this:
Code: mov eax,[assigned_file] cmp eax,-1 jne got_assigned_tab invoke SendMessage,[hwnd_tabctrl],TCM_GETCURSEL,0,0 got_assigned_tab: invoke SendMessage,[hwnd_tabctrl],TCM_GETITEM,eax,ei invoke MessageBox,[hwnd_main],[ei.pszpath],"Assigned path",MB_OK |
|||
![]() |
|
ProMiNick 30 May 2017, 10:26
fasmw.asm
Code: ... menu_command: and eax,0FFFFh mov ebx,[hwnd_fedit] ... cmp eax,IDM_FG_COMPILE je fgcompile ... fgcompile: mov eax,[assigned_file] cmp eax,-1 jne got_assigned_tab invoke SendMessage,[hwnd_tabctrl],TCM_GETCURSEL,0,0 got_assigned_tab: invoke SendMessage,[hwnd_tabctrl],TCM_GETITEM,eax,ei mov [path_buffer],0 cinvoke wsprintf,path_buffer,fgformat,[ei.pszpath] ;mov [sinfo.cb],sizeof.STARTUPINFO ;mov [sinfo.dwFlags],0 ;invoke CreateProcess,path_buffer,NULL,NULL,NULL,FALSE,CREATE_NEW_CONSOLE or NORMAL_PRIORITY_CLASS,NULL,NULL,sinfo,pinfo ;invoke CloseHandle,[pinfo.hThread] ;invoke CloseHandle,[pinfo.hProcess] invoke WinExec,path_buffer,SW_SHOW jmp finish fgformat: db 'C:\FASMG\searchbat.bat %s',0 ... IDM_FG_COMPILE = 1399 ... menu main_menu ... menuitem '&Run',0,MFR_POPUP ... menuitem 'FasmG compile',IDM_FG_COMPILE ... and added to fasmg dir 2 BAT files: makebin.bat Code: @echo off set include=C:\FASMG\examples\x86\include /fasmg/fasmg %1 %~dpn1.bin pause makeexe.bat Code: @echo off set include=C:\FASMG\examples\x86\include /fasmg/fasmg %1 %~dpn1.exe pause and in import WinExec added, because via createprocess - nothing happens. I commented it. that it is worked for me |
|||
![]() |
|
ProMiNick 02 Jun 2017, 23:12
topic linked to anotherhttps://board.flatassembler.net/topic.php?p=196902#196902
|
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2023, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.