Book a Demo

Author Topic: GetRelationSet ?  (Read 4657 times)

Mesple

  • EA User
  • **
  • Posts: 30
  • Karma: +0/-0
    • View Profile
GetRelationSet ?
« on: March 19, 2016, 01:54:56 am »
Hi all,

I would like to get the list of parent packages of a element and I use the "GetRelationSet" method of the "Element class" with "rsParents" but it doesn't work.
The string returned is always empty. :(
Any idea ?

Thanks a lot
Olivier

dim elementParents as string
dim currentElement as EA.Element
....
elementParents = currentElement.GetRelationSet(rsParents)

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +397/-301
  • I'm no guru at all
    • View Profile
Re: GetRelationSet ?
« Reply #1 on: March 19, 2016, 05:03:25 am »
GetRelationSet returns those with a connector to the element. You need to look at Element.PackageID and traverse from the package's ParentID.

q.

Mesple

  • EA User
  • **
  • Posts: 30
  • Karma: +0/-0
    • View Profile
Re: GetRelationSet ?
« Reply #2 on: March 24, 2016, 12:44:05 am »
Ok, I did it.
Thanks for your response  :)

Olivier