Community Tip - Stay updated on what is happening on the PTC Community by subscribing to PTC Community Announcements. X
Is it possible to run Hamilton C Shell Command in background
Try adding the following line to your config.pro:
terminal_command <full_path_of_C_Shell_Executable>
Hi,
please explain why do you need functionality of Hamilton C Shell.
MH
I want to convert Commercial creo lab files into Universal Format. While conversion Hamilton C Shell focus for every command.. It blocks the monitor . can't able to do any work simultaneosly on machine.
I tryied using following commands. It only hides Hamilton C Shell Command prompt
ShellExecute("csh.exe"," -LBINF",$CShellLoc,"",@SW_HIDE) .
Manoj
Hi,
please explain what do you get when you convert Commercial creo lab file into Universal Format.
For example:
source file = cube.prt
target file = ???
Note: It looks like you need to convert Creo native files into STEP, IGES or something else using some batch tool...
MH
Hi,
Files are successfully converted into Universal Format.
But while process it opens Hamilton C Shell . I want to run commands in Hamilton C Shell in Background. so that i can do other works also
Manoj
Hi,
I am sorry I do not understand your explanation. Therefore I have no idea how to help you.
MH
Hi,
I am using command
ShellExecute("csh.exe"," -LBINF",$CShellLoc,"",@SW_MAXIMIZE) .
I want to run Hamilton C Shell in Background.
Manoj
Now I realize that I didn't read the original question all the way to the end. My bad, please disregard my previous post.
Since you are trying to use "ShellExecute" I guess that you want to open C shell from a toolkit application. In the same time the syntax doesn't look quite right.What API are you using?
Manoj,
Are you trying to run a conversion program via the "open a system window" command in Creo Parametric where that system window is the Hamilton C shell? Or are you running the normal system DOS/CMD window from Creo Parametric, and trying to execute an AutoIT script to run the conversion?
When you run a "system" window from Creo Parametric, the shell window must close/exit in order for control to switch back to Creo Parametric.
If you want to launch an external program via the "system" window from Creo Parametric, and still be able to use Creo Parametric while that program is running "in the background", try using the START command in a mapkey for launching the system window.
An example mapkey to start a system window would be:
mapkey run_convert @MAPKEY_NAMEConvert to Universal Format;\
mapkey(continued) @MAPKEY_LABELConvert to Universal Format;\
mapkey(continued) @SYSTEMstart \/min \
mapkey(continued) C:\\ptc\\scripts\\creo\\parametric\\convert_2_uf.exe;
The above mapkey will open a DOS/CMD window, start the convert_2_uf.exe program, and close the DOS/CMD window while the convert program will continue to run.
If you're not using a mapkey, you can still use the START command from the system window, and just close out the original system window once your program starts.
Hopefully I have understood your question.
Regards,
Dan N.
Hi,
I have created AutoIT Script for conversion which launches Hamilton C Shell on Desktop.
For every file Hamilton C Shell Focus on Desktop.
My target is to run the process in Background.
Is any option available to run process in Background.