interpreter is in C++. I solved my problem.<br>When I run the exe from the interpreter, a command prompt is also opened with the exe.<br>I am closing this command prompt window and then interpreter goes to run the next code line.<br>
<br>thanks,<br>Vijdan<br><br><br><div class="gmail_quote">On Tue, Dec 8, 2009 at 3:50 AM, Jeff Shanab <span dir="ltr"><<a href="mailto:jshanab@earthlink.net">jshanab@earthlink.net</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Is your interpreter in C++ or Java? I just happened to be working with a<br>
java interpreter this weekend and needed input from the user.<br>
A simple dialog box was a basic 1 liner in java to get info from the<br>
user. I haven't looked but perhaps the same can be done in c++?<br>
<div><div></div><div class="h5"><br>
Csaba Toth wrote:<br>
><br>
> Hi Vijdan,<br>
><br>
><br>
><br>
> As far as I can understand this is a general programming issue.<br>
><br>
> We say that a call is synchronous (or blocking) if it won’t return to<br>
> the caller until the task is finished. An asynchronous (or non<br>
> blocking) call returns immediately to the caller point. In that case<br>
> it depends how you’ll be notified about the completion of the started<br>
> task. Sometimes you can specify some callback or delegate function, or<br>
> you have to set up some kind of IPC (inter process communication) or<br>
> periodically check some resource.<br>
><br>
><br>
><br>
> system is a standard C call and it is blocking (while _/exec//_execve<br>
> is not).<br>
><br>
><br>
><br>
> You need to start a new process or a thread and start your desired<br>
> program from there. Instead of using _exec I suggest to use CreateProcess:<br>
><br>
> <a href="http://msdn.microsoft.com/en-us/library/ms682425%28VS.85%29.aspx" target="_blank">http://msdn.microsoft.com/en-us/library/ms682425%28VS.85%29.aspx</a><br>
><br>
><br>
><br>
> This is it, if you just want to simply start a program like NotePad.<br>
> If you want to communicate with this process also, that cannot be<br>
> covered in this e-mail.<br>
><br>
><br>
><br>
> Hope that helps,<br>
><br>
> Csaba<br>
><br>
><br>
><br>
><br>
><br>
> *From:* <a href="mailto:gme-users-bounces@list.isis.vanderbilt.edu">gme-users-bounces@list.isis.vanderbilt.edu</a><br>
> [mailto:<a href="mailto:gme-users-bounces@list.isis.vanderbilt.edu">gme-users-bounces@list.isis.vanderbilt.edu</a>] *On Behalf Of<br>
> *Vijdan KIZILAY<br>
> *Sent:* Monday, December 07, 2009 10:33 AM<br>
> *To:* gme-users<br>
> *Subject:* [gme-users] runnning exe from GME dll<br>
><br>
><br>
><br>
> Hello,<br>
> I have a problem about running exe from a model<br>
> interpreter in GME.<br>
><br>
> I run for example<br>
> (void)system("C:\\WINDOWS\\NOTEPAD.EXE");<br>
> from the model interpreter code.<br>
><br>
> But when I run this exe, my code waits for the cmd to be closed<br>
> for going on.<br>
><br>
> I want my interpreter to goes on? Is there a way?<br>
><br>
> best regards<br>
> Vijdan<br>
><br>
</div></div>> ------------------------------------------------------------------------<br>
><br>
> _______________________________________________<br>
> gme-users mailing list<br>
> <a href="mailto:gme-users@list.isis.vanderbilt.edu">gme-users@list.isis.vanderbilt.edu</a><br>
> <a href="http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users" target="_blank">http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users</a><br>
><br>
<br>
_______________________________________________<br>
gme-users mailing list<br>
<a href="mailto:gme-users@list.isis.vanderbilt.edu">gme-users@list.isis.vanderbilt.edu</a><br>
<a href="http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users" target="_blank">http://list.isis.vanderbilt.edu/mailman/listinfo/gme-users</a><br>
</blockquote></div><br>