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:
Hi,
I have a problem with the new SearchManager function:
if I use only the Mastercam operation then it works fine,
but if I use the add-in HSM from cimco to create operations then the SearchManager ignores all these operations and return only the one from Mastercam.
What can I do?
Thanks in advance,
Silas
Hi,
I´m still working to transfer my program to nethook 2 from nethook 1...
How do you get the tooltype (for example: drill)
and the operationtype (for example: contour) as a string?
Dim selectedOps() As Mastercam.Database.Operation = SearchManager.GetOperations(True)
Dim op As Mastercam.Database.Operation
For Each op In selectedOps
ToolNo = op.OperationTool.Number.ToString
Toolname = op.OperationTool.Name
CurrentToolType = op.OperationTool.???????
Next op
(Sorry for double post)
Hi Martin,
the rename function works perfekt, thanks for writing me a dll for it.
Also the extra work for saving the setting.xml to a better place, I appreciate it.
Silas
Hi,
I´m still working to transfer my program to nethook 2 from nethook 1...
How do you get the tooltype (for example: drill)
and the operationtype (for example: contour) as a string?
For Each op In selectedOps
If op.Dirty = False Then
tooltype = op.OperationTool
operationtype = op.name
End If
Next op
Hi,
another problem: how can I post selected operations?
With this code nothing happend:
Public Shared Function PostOp(ByVal ncFilePath As String, ByVal boEdit As Boolean) As Boolean
Dim opInfos1 As Mastercam.Database.Operation
Dim flag_OP_Selected As Boolean
Dim flag_OP_Dirty As Boolean
Dim OpList() As Mastercam.Database.Operation = SearchManager.GetOperations()
Dim op As Mastercam.Database.Operation
For Each op In OpList
opInfos1 = op
flag_OP_Selected = opInfos1.Selected
flag_OP_Dirty = opInfos1.Dirty
If (flag_OP_Selected And Not flag_OP_Dirty) Then
PostOp = opInfos1.Post(ncFilePath, boEdit)
End If
Next op
End Function
Hi,
After I renamed the nci name of selected operations all 2d geometry like point, boundary's are lost, only the surfaces not.
Maybe I did something wrong in my code?
http://www.youtube.com/watch?v=wOI9xtVxBig
Public Shared Function RenameOperations(ByVal nci_Name As String) As Boolean
Dim opInfos1 As Mastercam.Database.Operation
Dim flag_OP_Selected As Boolean
Dim flag_OP_Dirty As Boolean
Dim intCount As Integer = 1
Dim nci_Verzeichniss As String = vbNullString
Dim OpList() As Mastercam.Database.Operation = SearchManager.GetOperations()
Dim op As Mastercam.Database.Operation
For Each op In OpList
opInfos1 = op
flag_OP_Selected = opInfos1.Selected
flag_OP_Dirty = opInfos1.Dirty
If (flag_OP_Selected And Not flag_OP_Dirty) Then
nci_Verzeichniss = System.IO.Path.GetDirectoryName(opInfos1.NCIName)
opInfos1.NCIName = System.IO.Path.Combine(nci_Verzeichniss, nci_Name & "_" & intCount & ".nci")
opInfos1.Commit()
intCount += 1
End If
Next op
End Function
Hi Martin,
I mean NETHook.
The version of the .NET Framewore are 4.0.0.
Yes I use the release version of mastercam.exe, is there a debug version available?
Hi,
I have trouble to run my chook with x5, I get an error "Unkown file type".
What can I do? The chook was written in vb.net.
I also tied the nethook 2 example for x4, but the same error appears.
(I use know Visual Basic 2010)
Silas
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.