How do you call and run another Revmade.exe
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
How do you call and run another Revmade.exe
I need to be able to call or run another exe programme made by Rev from the main one and then return back to the calling point to continue.
Can anyone tell me how this can be done?
Can anyone tell me how this can be done?
There are a few examples, depending on what you want to do in the Rev online viewer, under programming.
I know that it is possible, however it could and probably is somewhat difficult but it does not have to be that way.
You could just use a .REV file, again dont know what your goal is, or what type of communication you wish to achieve.
From what I read in the docs, using an external you could just about do anything you wanted to do, given enough time and energy.
have you downloaded the external kit, here is some information on externals, I have yet to jump into it but I know it is just a matter of time before I do, but not today, LOL
http://runrev.com/developers/tutorials/ ... ls-part-1/

I know that it is possible, however it could and probably is somewhat difficult but it does not have to be that way.
You could just use a .REV file, again dont know what your goal is, or what type of communication you wish to achieve.
From what I read in the docs, using an external you could just about do anything you wanted to do, given enough time and energy.
have you downloaded the external kit, here is some information on externals, I have yet to jump into it but I know it is just a matter of time before I do, but not today, LOL
http://runrev.com/developers/tutorials/ ... ls-part-1/

I think the easiest way would be similar to this approach:
As you see the easiest way isn't exactly an overly easy way 
Oh, and watch out for the paths (defaultfolder property), so you don't delete/read/check for a wrong file.
Code: Select all
--calling application
on mouseUp
--put something meaningfull into passedData here
put passedData into url ("file:" & "passedData.txt")
delete file "resultData.txt"
launch "/other/rev/aplication"
send "checkResult" to me in 10 seconds
end mouseUp
on checkResult
if there is a file "resultData.txt" then
send "checkResult" to me in 10 seconds
else
put url ("file:" & "resultData.txt") into theResult
-- do other stuff here
end if
end checkResult
Code: Select all
on startup
put url ("file:" & "passedData.txt") into theInput
-- do stuff here
put theOutput into url ("file:" & "resultData.txt")
end startup

Oh, and watch out for the paths (defaultfolder property), so you don't delete/read/check for a wrong file.
Various teststacks and stuff:
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
To Reelstuf and Bvg,
Thank you for your suggestions.
In simple terms then, MainProg is running and reaches a point where SecondaryProg.exe is called.
MainProg.exe saves data that needs to be used by SecondaryProg.exe in a text file, SecondaryProg.exe starts and reads the text file, then does its processing and saves the result back to a text file and terminates.
MainProg.exe is the currently running program, so perhaps a continue button is pressed and the Result file is read and the MainProg.exe continues.
If this is what you had in mind BvG, in your code, then that looks to be just what I want.
Thank you for your suggestions.
In simple terms then, MainProg is running and reaches a point where SecondaryProg.exe is called.
MainProg.exe saves data that needs to be used by SecondaryProg.exe in a text file, SecondaryProg.exe starts and reads the text file, then does its processing and saves the result back to a text file and terminates.
MainProg.exe is the currently running program, so perhaps a continue button is pressed and the Result file is read and the MainProg.exe continues.
If this is what you had in mind BvG, in your code, then that looks to be just what I want.
Yes that's what the code does. Well mostly... there's no button, "MainProg.exe" would just continue when there is data in the correct file (resultData.txt).
You did look at the code and understood what it does, right?
You did look at the code and understood what it does, right?
Various teststacks and stuff:
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
http://bjoernke.com
Chat with other RunRev developers:
chat.freenode.net:6666 #livecode
I will study it when I get time.
I have been plunged back into work again, so it may be several days before I can study and experiment. Be assured, I would be programming it now if I could.
For your interest, the software I am writing is very ordinary at a technical level, but is quite unique in its application. It also has a ready made market of professionals ready to use it. So I am trying very hard to get it out there for them.
In case you think I am going to make a fortune from it, the product will be free. That is why no one else would produce this essential tool. I dont need the money, but I would like to leave something worthwhile behind when I kick the bucket.
In the same way, all you people who help users like me are making a difference and it is appreciated.
I have been plunged back into work again, so it may be several days before I can study and experiment. Be assured, I would be programming it now if I could.
For your interest, the software I am writing is very ordinary at a technical level, but is quite unique in its application. It also has a ready made market of professionals ready to use it. So I am trying very hard to get it out there for them.
In case you think I am going to make a fortune from it, the product will be free. That is why no one else would produce this essential tool. I dont need the money, but I would like to leave something worthwhile behind when I kick the bucket.
In the same way, all you people who help users like me are making a difference and it is appreciated.