From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
04-16-2013 04:34 AM
Hello Experts,
I am in trouble with an ActiveX Call. Given an application called: Mach3 a CNC program. Link: http://www.machsupport.com/downloads.php Mach3 R3.043.066
I would like to interface it with LabVIEW via ActiveX. I found a similar topic in NI forum but the questioner uses LabWindows/CVI. Link: http://forums.ni.com/t5/LabWindows-CVI/ActiveX-controller-methods-import-as-callbacks/td-p/1038846
After installing the Mach3 on WindowsXP 32Bit, I found the tlb file that can be used for ActiveX calls under the following path: C:\Mach3\Mach4.tlb.
When I check : "Show Creatable Object Only" I can not see the complete list of ActiveX calls and function returns an error:
Class is not registered.
I've registered the Mach4.tlb file with regtlb.exe under Windows\.NET\Framework without any success.
Selecting IMyScriptObject to open, the ActiveX calls appeared but I always got an error message: Object specified is not creatable in ...
Could you give me some help how to go on? Looking forward you kind reply!
Solved! Go to Solution.
04-19-2013 06:49 AM
Hi!
I've downloaded the current versin of Mach3. What worked for me was:
1. Restarting computer after installing Mach3.
1. Make sure Mach3 is running in the background, without that, class objects we not available.
2. Create an Automation Open, with a constant as the input.
4. Browse for object class, select:
5. There's a handful of methods available for that particular class. This code checks the revision nr.:
This is what I was capable of reaching via LV ActiveX.
Hope this helps.
Regards:
Andrew Valko
NI Hungary
04-19-2013 07:18 AM
Thank you so much for your help. I have tried something similar to your code, but Mach3 was not running. You are great!
11-22-2014 03:22 PM
HI, I am also working on the same thing.
But I need to use the functions which are in the non-creatable classes IMyscriptobject.
from the this earlier post on Lbawindows CVI , http://forums.ni.com/t5/LabWindows-CVI/ActiveX-controller-methods-import-as-callbacks/td-p/1038846
I understand that we need the following steps(correct me if am wrong)
// get Imach4(which we do when we invoke node after giving the refunm and autmation open)
Mach4_ActiveIMach4 ("c:\\Mach3\\Mach3.exe", 1, LOCALE_NEUTRAL, 0, &MachHandle);
//get SprictObjectHandle using GetScript Dispatch ( we have this function in Ithe node IMach4 we created earlier)
Mach4_IMach4GetScriptDispatch (MachHandle, NULL, &ScriptObjectHandle);
// get the final function needed from scriptobjecthandle.
Mach4_IMyScriptObjectCode (ScriptObjectHandle, NULL, "G20 x-1 z-1 y-1");
How can we do this is Labview (with just the GUIs)
For example, I want to use DoOemButton(135) . How would I do that.
Thanks in advance.
11-06-2018 04:47 AM
hello
i also same problem have
Mach3 ActiveX use make Labview VI
i find your Answer
then i try make Same make ,
if run exec Mach3.exe just run......
i just want use dll.. but can't?
Please help your answer
03-18-2019 01:01 PM
I found additional information that might be helpful here. On the NewFangled Solutions MachSupport forum I found this post that also explains how to get more useful features out of the ActiveX object in LabVIEW.
It was posted by a user SamZ at https://www.machsupport.com/forum/index.php?topic=23525.msg165202#msg165202
I hope this helps someone else.
07-06-2020 02:12 AM