Great! One problem.... if the assembly contains library files (for example, an electric cabinet that contains hinges that reside in a library folder) the rule does not work because it cannot modify or write the parameters in those library files (in the hinges). is it possible for the rule to ignore library files?
this is very convenient. if i make a drawing for one configuration and then i need to make another drawing for another configuration from this same assembly, will my drawings for both configurations be conflicted? it seems like every time a configuration is changed, it will also update the drawing.
I get an error on line 59, when I paste your iLogic code and attempt a save. I can move forward, but any change to the value in my Form doesn't change the lengths of the necessary parts.
Sorry, I didn't see your comment. You have to create a parameter with the same name in your parts for Inventor to find it. You could write extra code to create these parameters automatically but my code won't do that.
I've goptten it to work, but when I try to add a new part and run the rule I get this error: Error on line 29 in rule: lengte, in document: 14-0122-00-01_L802(L)S.iam The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG)) System.ArgumentException: The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG)) at System.RuntimeType.ForwardCallToInvokeMember(String memberName, BindingFlags flags, Object target, Int32[] aWrapperTypes, MessageData& msgData) at Inventor.UserParameters.AddByExpression(String Name, String Expression, Object UnitsSpecifier) at ThisRule.CopyUserParams() in rule: lengte, in document 14-0122-00-01_L802(L)S.iam:line 29 at ThisRule.Main() in rule: lengte, in document 14-0122-00-01_L802(L)S.iam:line 2 at Autodesk.iLogic.Exec.AppDomExec.ExecRuleInAssembly(Assembly assem) at iLogic.RuleEvalContainer.ExecRuleEval(String execRule) What am I doing wrong?
Great! One problem.... if the assembly contains library files (for example, an electric cabinet that contains hinges that reside in a library folder) the rule does not work because it cannot modify or write the parameters in those library files (in the hinges). is it possible for the rule to ignore library files?
Clear, to the point, and most importantly, it works flawlessly. Thank you
This is fantastic . Thanks for the video
this is very convenient. if i make a drawing for one configuration and then i need to make another drawing for another configuration from this same assembly, will my drawings for both configurations be conflicted? it seems like every time a configuration is changed, it will also update the drawing.
Fantastic
I get an error on line 59, when I paste your iLogic code and attempt a save. I can move forward, but any change to the value in my Form doesn't change the lengths of the necessary parts.
Great vid! But I have one problem. I assigned "user parameters" in my top assembly but can't access them in my parts. Any idea what's wrong?
Sorry, I didn't see your comment.
You have to create a parameter with the same name in your parts for Inventor to find it.
You could write extra code to create these parameters automatically but my code won't do that.
how do you take this and make it in to a template? where the parts comes out as new parts?
Easiest way is to do a copy design on it first. Either through iLogic copy design or through vault.
LOL i liked your boooom
I've goptten it to work, but when I try to add a new part and run the rule I get this error: Error on line 29 in rule:
lengte, in document: 14-0122-00-01_L802(L)S.iam
The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
System.ArgumentException: The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
at System.RuntimeType.ForwardCallToInvokeMember(String memberName, BindingFlags flags, Object target, Int32[] aWrapperTypes, MessageData& msgData)
at Inventor.UserParameters.AddByExpression(String Name, String Expression, Object UnitsSpecifier)
at ThisRule.CopyUserParams() in rule: lengte, in document 14-0122-00-01_L802(L)S.iam:line 29
at ThisRule.Main() in rule: lengte, in document 14-0122-00-01_L802(L)S.iam:line 2
at Autodesk.iLogic.Exec.AppDomExec.ExecRuleInAssembly(Assembly assem)
at iLogic.RuleEvalContainer.ExecRuleEval(String execRule)
What am I doing wrong?
nothing happened on the last boom.
That's because I didn't run the code. It would change immediately if I had the code set to run automatically, but I turned that off.