I would like to run another program from inside a BASIC+ program. I would like to have the program run modally and minimized.
I used the following statement:
void=utility("RUNWIN","program.exe",-6)However, while the program runs minimized, it does not run modally.
Can anyone help?
Hi Steve,
I'm not an expert, but I do not think it is possible for OI32 to do a RUNWIN with a modal (actually, I think synchronous execution may describe what you are trying to do better) option. In Win16, no problem, because WinExec() returns the procid of the application and OI can loop until the procid is gone. In Win32, it is not that simple. If you know the caption of the application that you are executing, then you can disable your GUI (an OI form I assume), call RUNWIN (with the minimize option), then use FindWindow(), and then loop until FindWindow() fails to find the application. This is not perfect, but it may work.
Tony
I'm sending you a bunch of programs which will do modal stuff really well. It's called MS-DOS 6.22….
![]()
Sorry, but after years of trying to get PCs into multi-tasking multi-threaded operating systems, it seems a little ironic that you'd simply be trying to switch that functionality off…
Which app are you trying to run out of OI??? What are you trying to achieve? It may be possible to call the classes and DLLs associated with your "modal" task in such a way that the application behaves appropriately.
Describe your problem a little more.
I don't see FindWindow() in the OI documentation. Is this a Windows function?
Wayne