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:

adding drive solid to Surf Rough Contour


Recommended Posts

Hi guys,

 

Newbie NetHook programmer here.

NetHook2_0.dll

X2_MR2

 

I have the following code to add a solid to an operation I've imported. However, I can't find the docs or an example that tell me how to access / manipulate the Surface Rough Contour. All I can find seems to talk about 2D ops.

 

 

code:

         Public Overrides Function Run(ByVal param As Integer) As MCamReturn

 

Dim strOpsFile As String = "J:MasterCamTestTemporaryOpsFile.mcx"

Dim intOpID As Integer = 2

 

'-> place all solids into an array

Dim objSolids() As Mastercam.Database.SolidGeometry

objSolids = Mastercam.Support.SearchManager.GetSolidGeometry()

 

'-> as a test, report the number of solids found

MsgBox("number of solids found: " & CStr(objSolids.Length))

 

'-> loop thru the array of solids, import an operation for each and add the solid to the op

For intI As Integer = 0 To objSolids.Length

'-> import the rough surface contour operation

Dim OpImport As Mastercam.Database.Operation

OpImport = Mastercam.Operations.OperationsManager.ImportOperation(strOpsFile, intOpID, True, True)

 

'-> code here to somehow add each solid to the imported operation

 

Next

 

Return MCamReturn.NoErrors

End Function

My questions are:

1. Where in the object browser do I find the objects dealing with surface / solid tool paths.

2. What would the code look like to add the solids in my array to the drive surface of the surface rough cuts?

 

Thanks in advance.

Link to comment
Share on other sites

Roger,

 

Thanks for the quick reply. This functionality is fundamental to the project I was hoping to implement - nesting of solids.

 

Do you have an ETA of when these functionalities will be exposed in .net? I really can't justify learing C++ for this project. Unigraphics has a similar problem when they went from C++ based API to the .NET system. They addressed it by wrapped the C++ functions as vb.net. Do you have any plans to possibly do this?

 

Thanks again for your help.

 

Roger James

Link to comment
Share on other sites

quote:

Do you have an ETA of when these functionalities will be exposed in .net?

Roger,

 

They're not wrapping everything with .NET that you can do via the CHook SDK - unless they get requests for something specific.

 

I would suggest that you detail what functionality that you're looking for (and provide some details as to your ultimate goal for using this functionality) and submit it your request to [email protected]

 

*While there is no guarantee that this will get you those functions, if you or no one else asks for them, you probably will not see them "just appear" in the API.

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...