Hello Guest it is December 14, 2024, 06:30:23 AM

Author Topic: Running Mach3 via VB.NET in the year 2014  (Read 2381 times)

0 Members and 1 Guest are viewing this topic.

Running Mach3 via VB.NET in the year 2014
« on: October 02, 2014, 09:23:30 AM »
Hello,

I want to controll Mach3 via a vb.net application I am writing. After searching in google and this forum i always found the same Threads. This one is one of them. http://www.machsupport.com/forum/index.php/topic,12893.0.html. So I thought there must be a way to realize it. The problem is, that all the posts and threads are at least five years old and seemed to be no solution fore me. My version of vb.net (vb.net 2013 express) didn't work with the suggested solutions.
Is there an API existing that I can import in vb.net to control Mach3. I've tried to add the references but when I run an example project it always throws an exception.

Here the example code from the linked thread i try to use

Code: [Select]
Dim mach As Mach4.IMach4
Dim scriptObject As Mach4.IMyScriptObject
mach = GetObject(, "Mach4.Document")

When running the third line this exception is thrown (translated from german)
Code: [Select]
System.Exception: The ActiveX component can't be created...

Please excuse my poor english. I am not a english nativ speaker

Thx