Strange, Windows app working in Linux?
Posted: Mon Dec 25, 2006 5:50 pm
I was messing around on my backup drives and was testing to launch a few test programs I wrote for Windows some time ago. And some of them actually work perfectly. I haven't, that I know of, installed any emulators or anything like that. Just launched the program and it works.
Here's the code of one of the programs that works, it uses Windows API of all things
Here's the code of one of the programs that works, it uses Windows API of all things
Code: Select all
Result = MessageBox_(0,"This is the text","This is the caption",#MB_CANCELTRYCONTINUE|#MB_ICONINFORMATION|#MB_DEFBUTTON2)
Select Result
Case #IDABORT ; Abort button was selected.
Selected$ = "IDABORT"
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
Case #IDCANCEL ; Cancel button was selected.
Selected$ = "IDCANCEL"
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
; Case #IDCONTINUE ; Continue button was selected.
; Selected$ = "IDCONTINUE"
; MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
Case #IDIGNORE ; Ignore button was selected.
Selected$ = "IDIGNORE"
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
Case #IDNO ; No button was selected.
Selected$ = "IDNO"
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
Case #IDOK ; OK button was selected.
Selected$ = "IDOK"
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
Case #IDRETRY ; Retry button was selected.
Selected$ = "IDRETRY"
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
; Case #IDTRYAGAIN ; Try Again button was selected.
; Selected$ = "IDTRYAGAIN"
; MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
Case #IDYES ; Yes button was selected.
Selected$ = "IDYES"
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
Default
Selected$ = Str( Result )
MessageBox_(0,"You select " + Selected$ + ".","Result",#MB_OK)
EndSelect
End
;- End of program
; IDE Options = PureBasic v4.01 (Windows - x86)
; Folding = -
; Executable = API_MessageBox.exe