Jump to content

Welcome to eMastercam

Register now to participate in the forums, access the download area, buy Mastercam training materials, post processors and more. This message will be removed once you have signed in.

Use your display name or email address to sign in:

Select Surfaces in VBScript?


Recommended Posts

I need to have the user select some surfaces then change the level and color of the selected entities? I can select Lines, Arcs. Points and Chains but can't figure out how to get the surfaces.

 

Even better would be to  allow the user to select a window of surfaces. Is this possible in VBScript or do I need to create a c-hook ?

 

Thanks

Karl S.

Link to comment
Share on other sites

Thanks Roger,

     The ultimate goal is to automate some of our very repetitive tasks here. This would be used for MCam X7 and X8.

I'll start working in the nethook environment as this seems to have a lot more power for what we're doing here. Yea something to learn:)

Would need it to do the following:

1) Import a parasolid model.

2) Organize the entities ( Might not be needed ) -  Easy except for the surfaces, hence the above question

3) Load operations from default file

4) Add selected entities to Toolpaths

5) Regenerate and Post 

 

Thanks again for the reply.

Karl

Link to comment
Share on other sites
It always starts with a single simple “how do I…” question and then…!

 

Would need it to do the following:

 

1) Import a parasolid model.

Simple:  Mastercam.IO.FileManager.Open(filename);

 

2) Organize the entities ( Might not be needed ) -  Easy except for the surfaces, hence the above question

I have a sample NET-Hook project that prompts the user to Window select entities and

then it moves the Surfaces to “other” levels and optionally changes their color.

 

3) Load operations from default file

Yes…

 

4) Add selected entities to Toolpaths

*Depending on the type of the toolpath. Not all types can be done.

 

5) Regenerate and Post 

Yes…

 

Link to comment
Share on other sites

Thanks Roger, Yes that's so true. All of my scripts whether for windows, Solidworks or MasterCAM started with a simple "can this be done by the computer instead of by me"...:)

 

Does Mastercam install any Net-Hook samples like it does with the VB scripts? I am assuming I need to get the SDK, is that available on the web or as a paid thing from our dealer?

 

Thanks for the help.

Link to comment
Share on other sites

Thanks Roger, Yes that's so true. All of my scripts whether for windows, Solidworks or MasterCAM started with a simple "can this be done by the computer instead of by me"... :)

 

Does Mastercam install any Net-Hook samples like it does with the VB scripts? I am assuming I need to get the SDK, is that available on the web or as a paid thing from our dealer?

 

Thanks for the help.

 

Karl,

 

No NETHook SDK install is required, when you install Mastercam the NETHook API is available when referencing the NETHook_3.0.dll, located in your Mastercam folder, in your .NET project.

 

We are actively developing example projects, there is a VB.NET and C# Nesting project that should be available in the next day or two and I reply to this thread once it is available for download.

Edited by Mick from CNC Software Inc.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.

Join us!

eMastercam - your online source for all things Mastercam.

Together, we are the strongest Mastercam community on the web with over 56,000 members, and our online store offers a wide selection of training materials for all applications and skill levels.

Follow us

×
×
  • Create New...