Message 1 of 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello everyone,
I want to activate the state of the "Main" model in an iam assembly in iLogic coding.
To do this, I'm using these few lines
I have not provided the lines of code from line 1 to 18 because they are comment lines requested by the client.
So, in the interests of confidentiality, I haven't included them in the attached screenshot.
Dim ADoc As AssemblyDocument = DirectCast(ThisApplication.ActiveDocument, AssemblyDocument)
Dim ACDef As AssemblyComponentDefinition = ADoc.ComponentDefinition
ACDef.ModelStates.Item("Principale").Activate()
Unfortunately, these lines of code return the following error message:
This seems to be a fairly common error message on the forums, but I can't find a solution to my problem.
Would you have an idea for me, thank you.
Solved! Go to Solution.