Community
Inventor Forum
Welcome to Autodesk’s Inventor Forums. Share your knowledge, ask questions, and explore popular Inventor topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Run Ilogic Rule based on user?

3 REPLIES 3
SOLVED
Reply
Message 1 of 4
DeerSpotter
324 Views, 3 Replies

Run Ilogic Rule based on user?

Would this be possible? If it is, i would like to be able to choose event triggers for certain rules based on the user type. Some users here dont know what from what sometimes, and a friendly message before they close the document like "did you check this?" would be really nice. 

 

If (ThisDoc.Document.DocumentType <> kDrawingDocumentObject) Then Return

IF ThisApplication.GeneralOptions.Username = username1 Then

XXXXXXXXXXXXXXXXXXX

Else IF

XXXXXXXXXXXXXXXXXXX

End IF
Image and video hosting by TinyPic
..........................................................................................................................
Did you find this reply helpful ? If so please use the Accept as Solution or Kudos button below.
..........................................................................................................................


See My LinkedIn Profile
3 REPLIES 3
Message 2 of 4

Hi m.teleguz1,

 

I think what you have is very close, but here's a working example. This rule checks to see if the file is not a drawing file, if it is a drawing, then it looks to see if the username matches my username: "CurtisW". So if it is me, then the rule ends, if it is not me, then the rule passes the reminder message to the user.

 

I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com

 

oUserName = ThisApplication.GeneralOptions.Username
If (ThisDoc.Document.DocumentType <> kDrawingDocumentObject) Then 
Return
Else
	If oUserName <> "CurtisW" Then
	MessageBox.Show("Hey " & oUserName & " don't for get to ____________!", "iLogic")
	End If
End If

 

Message 3 of 4
mcgyvr
in reply to: Curtis_Waguespack

I can have some FUN with that one 🙂

 



-------------------------------------------------------------------------------------------
Inventor 2023 - Dell Precision 5570

Did you find this reply helpful ? If so please use the Accept Solution button below.
Maybe buy me a beer through Venmo @mcgyvr1269
Message 4 of 4

This is great!

oUserName = ThisApplication.GeneralOptions.Username
If (ThisDoc.Document.DocumentType <> kDrawingDocumentObject) Then 
Return
Else
	If oUserName <> "TELEGUM" Then
	MessageBox.Show("Hey " & oUserName & " don't for get to ____________!", "iLogic")

iLogicVb.RunExternalRule("G:\Drawings\testrule1.iLogicVb")
	End If
End If

 I can run rules too! 

Thanks!

Image and video hosting by TinyPic
..........................................................................................................................
Did you find this reply helpful ? If so please use the Accept as Solution or Kudos button below.
..........................................................................................................................


See My LinkedIn Profile

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report