[Integrity Modeler] How to create a block property, assing a stereotype and adopt the style via script.
Jul 05, 2016
03:17 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Jul 05, 2016
03:17 AM
[Integrity Modeler] How to create a block property, assing a stereotype and adopt the style via script.
Hello community,
I actually have this piece of code as a toolbar script (SysML-Profile used):
Option Explicit
Function ValidInsertionPoint()
ValidInsertionPoint=True
End Function
Function SelectObject()
SelectObject=False
Script.AddResultObject SysML::BlockProperty
msgbox NewSymbol
SelectObject=True
End Function
Function OnFinished()
dim NewClass
set NewClass = NewSymbol.Item("Dict Item")
dim NewClass1
set NewClass1 = NewClass.Item("Class")
msgbox NewClass1
call NewClass.Add("Stereotype", mBlockProperty)
call NewClass1.Add("Stereotype",mBlock)
msgbox NewSymbol
OnFinished=True
End Function
With that I've got 2 problems:
- The created item is of type "Role", not of Type "BlockProperty". How can I change this?
- The stereotype is assigned, but the style is still not adopted, even though I have the checkbox "Apply to New Symbols" checked.
Can anybody help me?
Thanks a lot and best regards,
Markus
Labels:
- Labels:
-
Modeler
0 REPLIES 0
