So we build our own BOM on our drawings, and now we're supporting customization of individual BOMs. I built a tool that allows this to be done automatically, but I'm seeing strange behaviour sometimes. Basically, most of the time I have to treat a compound note as a collection of separate text fields using
- Note.GetTextCount()
- Note.GetTextAtIndex()
- Note.GetTextPositionAtIndex()
but then sometimes it won't work unless I use the CompoundText methods,
- Note.GetCompoundTextCount()
- Note.GetCompoundTextAtIndex()
- Note.GetTextOffsetAtIndex()
To make matters worse, GetTextOffsetAtIndex() and GetTextPositionAtIndex() both fail (the former returning {0,0,0} and the latter null) when called while the note is in CompoundText mode.
Anyone have any insight? I'm pulling my hair out.
SolidworksApi macros