Hello Guest it is November 22, 2019, 07:46:31 AM

Author Topic: External LoadFile command  (Read 3146 times)

0 Members and 1 Guest are viewing this topic.

External LoadFile command
« on: April 29, 2015, 12:29:29 PM »
Hi everyone!

I'm currently trying to build an external C++ program that utilizes the scripting function in Mach 3 based off the MachRemote example on the main site.  I have added a "Load File" button to the screen, sourced it correctly, and am able to run other scripting commands on it like scripter.DoButton(21) and scripter.DoOEMButton(169) so I know the button is sourced and functions correctly.

It is not allowing me to use the LoadFile or LoadRun command.

Here's the section of code that I have:
Code: [Select]
void CMachRemoteDlg::OnBnClickedLoadFile()
if (scripter == NULL) return;

Any suggestions as to why this would not work?
Re: External LoadFile command
« Reply #1 on: April 30, 2015, 02:29:19 PM »
I found out that I have to be in the Open File dialog box in order for the LoadFile and LoadRun commands to execute properly.  Anyone know of a way in which I am able to do this without opening this dialog box?  Or how to close it in proper sequence if its necessary to have it open while loading a GCode file?
Re: External LoadFile command
« Reply #2 on: June 07, 2015, 12:58:45 PM »
whether you are able to do load g code using an external button I have to find a way to quickly load code