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:
Yes, you can use c++ libraries in c#, however you must compile the dll using c++/cli
You can use this project
Mastercam C++/CLI New Project Template VS 2022 - Visual Studio Marketplace
That's very true, however that's a limitation of the import manager not Mastercams API,
The Nesting Manager can import solids fine
Import Operations With Solids – myMastercam
Those operations are not supported by the api, there is also a bug with commit, the chook api is far better suited for these tasks,
for most tasks involving toolpaths the nethook api is not suitable
There is not currently a way to do this without third party software AFAIK,
my company provides solutions like this for a fee for customers,
feel free to reach out if you are interested.
Mastercam C++/CLI New Project Template VS 2022 - Visual Studio Marketplace
This template contains a c# example of translating geometry using the chook api with an interop dll, which will likely mitigate your issue
Solid surfaces are store as toolpath entities the way drill points are or chains, they contain parasolid ids for the toolpath api to lookup the geometry,
translating the geometry with a chook call and regenerating the operation should work, however,
if the op is using the nethook API, calling .Commit() on the solid could invalidate the associated toolpath entities. Sometime calling Commit(false) solves the issue, however i would recomment using the chook api for advanced operations like unified
in the older versions you could lookup the solid surfaces and other toolpath info by dumping the database
That sounds right MFC is being slowly replaced with wpf in Mastercam.
Wpf has a more modern look and has graphical ui elements instead of subwindows.
They were talking about it in the developer Event when they covered the new managed ui.
Leaving a read me file explaining the process should be sufficient to mitigate any confusion.
I'm simply stating that the way you are suggesting is mid at best, and extremely problematic at worst.
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.