Search element by its ID

Starting point for “ask and learn more about MagicDraw”

Moderator: Moderators

Search element by its ID

Postby Kristina B » Thu Aug 13, 2020 8:50 am

Hi, Is there a way to find element by its ID (the long with many numbers and underscores one?)

Thank you in advance,
Kristina
Kristina B
Forum Newbie
Forum Newbie
 
Posts: 1
Posts Rating:0
Joined: Thu Aug 13, 2020 8:40 am

Re: Search element by its ID

Postby ogirdor » Mon Aug 17, 2020 8:34 am

You can write a plugin to do that, I have done that in the past. You enter the ID and the corresponding element gets selected in the Containment tree.

You can use getElementByID for that.
ogirdor
Forum Beginner
Forum Beginner
 
Posts: 48
Posts Rating:14
Joined: Wed Jun 03, 2020 4:41 am

Re: Search element by its ID

Postby ogirdor » Mon Aug 17, 2020 8:36 am

Another way would be to create a generic table showing the ID for all the relevant elements and use the filter to find the one you are looking for
ogirdor
Forum Beginner
Forum Beginner
 
Posts: 48
Posts Rating:14
Joined: Wed Jun 03, 2020 4:41 am

Re: Search element by its ID

Postby kristina.belousova@airbus.com » Mon Aug 17, 2020 8:47 am

ogirdor wrote:Another way would be to create a generic table showing the ID for all the relevant elements and use the filter to find the one you are looking for

Thaks for both suggestions, will give them a go.
kristina.belousova@airbus.com
Forum Newbie
Forum Newbie
 
Posts: 1
Posts Rating:0
Joined: Mon Aug 17, 2020 8:45 am

Re: Search element by its ID

Postby GLHF » Thu Aug 20, 2020 6:29 am

Hi,

Solution:

Edit - Find

Enter Prefix "xmi.id="+id

Example

xmi.id=_19_0_2_16100410_1584959669489_301118_198087

Hope this helps.
GLHF
Forum Newbie
Forum Newbie
 
Posts: 22
Posts Rating:5
Joined: Wed Aug 05, 2020 6:17 am

Re: Search element by its ID

Postby ogirdor » Thu Aug 20, 2020 7:10 am

Nice one! Is that documented somewhere?
ogirdor
Forum Beginner
Forum Beginner
 
Posts: 48
Posts Rating:14
Joined: Wed Jun 03, 2020 4:41 am


Return to New to MagicDraw

Who is online

Users browsing this forum: No registered users and 0 guests