Home > Customise Mastercam with VB script

Customise Mastercam with VB script

Supplier News
article image

MASTERCAM Version 9.1, distributed by Technology Sales and Support , includes dozens of new features designed to simplify complex processes, improve speed, and expand shops' capabilities.

Among them is the ability to run programs written in Microsoft Visual Basic.

VBScript support expands Mastercam's ability to automate repetitive tasks, gives users the ability to customise functions, and creates opportunities for a wide array of specialised utilities.

CNC Software president Mark Summers said VBScripts allowed users to create powerful, specialised software tools that run within Mastercam.

“For example, one function we've programmed using VBScript automatically imports, analyses, and toolpaths parts coming from certain CAD packages.

“Imagine a folder containing more than 100 part drawings that need to be opened and programmed. To do this 'manually' would take a long time. “Using VBScript, you can write a program to do it faster, and reduce the chance of user error."

VBScript support makes it possible to read Microsoft Excel, ACT!, Oracle, and other file formats directly into Mastercam.

With VBScript, users can create customised functions that automatically create part geometry based on spreadsheet data.

Another tool created using VBScript enables Mastercam users to recreate similar geometry using parametric values. Mastercam prompts the user for key values and automatically creates the geometry.

"The number of programmers with knowledge of VBScript has increased significantly in recent years, making it easier than ever for shops to find people capable of creating the kind of advanced specialty functions they're looking for," Summers added.

Mastercam has always been ‘open’ so anyone could write add-ons with C programming.

Now, people who don't know C have the same capability. In fact, for simple add-ons, users don't even need to know Visual Basic.

With the Mastercam VBScript Editor, users can customise functions using a simple process similar to writing a macro in most Microsoft programs.

The Editor also includes features like Syntax Highlighting, Intellisense, Bookmarks, and Commenting, designed to make the process as intuitive as possible.

Newsletter sign-up

The latest products and news delivered to your inbox