okay, I created this Public class and Public function vb project
Public Class ClassNCupload
PublicFunction ncload(ByVal strNcName As String) AsString
Dim y AsNew WPNCTR.NCTRService
Dim result As String
Dim strErrDesc AsString = ""
Try
result = y.NCTransfer(strNcName, strErrDesc)
If result = "000"Then
MsgBox("NC upload successful")
Else
MsgBox("Error in WPNCTR - "& result & vbCrLf & strErrDesc)
EndIf
Catch ex AsException
MsgBox(ex.Message.ToString & vbCrLf & vbCrLf & ex.ToString)
Finally
EndTry
EndFunction
End Class
then compiled it as a dll NCupload.dll
This is a simplified version of my external rule
Add Reference "NCupload.dll
Sub Main
Dim strNcName As String
strNcName = "my string"
' now here i want to call the NCupload.dll , pass the value of strNcName to the dll and have it run
' anyone poin
End Sub
Can anyone explain how i call the dll and pass the string variable value
thanks
Hi,
Here is a blog post which does the same:
http://adndevblog.typepad.com/manufacturing/2013/06/use-vbnet-dialog-in-ilogic.html
I hope this helps.
Cheers,
Adam, thanks for the link to the article it is very interesting.
Prior to seeing this I had a lot of help from Mike Deck at Autodesk and i can now successfully call my dll from the ilogic rule 🙂
Hello,
I would like to know what is the function of "Class this reule" in inventor Ilogic.
Please let me know is there any sample tutorial on same.
Hi Swordmaster
and Hi MaheshwarMD
I'm from the rule set used ilogic .dll file
But I have difficulties later
I've used the .dll file as a form
There currently are having problems are not used vb.net code dialog
Example simple as
dim a as double = 1
dim b as double = 2
dim c as double
c = a + b
msgbox (c) o
I can not Addreference in ilogic, because it does not contain the dialog as the instructions
Thanks