Page 1 of 1

External program displayed

Posted: Mon 17 Aug 2015 1:27 pm
by gluepack
I think everything is ok so far. It ran first time but I had to make some mods involving changing folder references in the config file.
One thing that I notice is that now, every time that the external program (a batch file) is invoked, a command prompt window is displayed showing its progress. Is this a Cumulus thing or something else?

Re: External program displayed

Posted: Mon 17 Aug 2015 5:41 pm
by gluepack
It's ok, Googling found me some code for a VBS...

Set WshShell = CreateObject("WScript.Shell" )
WshShell.Run chr(34) & "C:\WinSCPMX\upreally.bat" & Chr(34), 0
Set WshShell = Nothing

... that calls my batch file, so the VBS is my "external program" now, instead of the BAT and the command prompt window no longer displays.

I'm not an expert but is it something to do with you using a DOS call now, instead of a WIN call, for the external program?

Re: External program displayed

Posted: Tue 18 Aug 2015 8:52 am
by steve
gluepack wrote:I'm not an expert but is it something to do with you using a DOS call now, instead of a WIN call, for the external program?
The underlying mechanism is the same, but MX uses .Net, so the system calls that it makes are different. With the 'daily' program, I've specified the 'CreateNoWindow' option, but I haven't done that for the others. I'll change it to do that, so hopefully that will fix it.

Re: External program displayed

Posted: Tue 18 Aug 2015 10:19 am
by gluepack
Thanks