Inventor Customization

Inventor Customization

Reply
Contributor
RPdAnjou
Posts: 33
Registered: ‎06-06-2011
Message 1 of 3 (209 Views)

Finding "Where Used" or recreating the "Open Drawing" command using the API

209 Views, 2 Replies
07-17-2012 04:16 AM

Hi,

 

I know there are a few posts about "where used" and opening/printing drawings of all components in a assembly, but to be as flexible as possible I would like to ask about this issue a bit more specific. 

 

The RMB command "Open Drawing" will open the drawing that uses the component.

My question is, how can I reproduce this behavior trough the API?

Even more interesting would be, how can I get a reference to the "Where Used" components. I know components don't know where they are used, but how do I figure this out the easy way with the API.

 

Can this be done by calling this command directly or can I maybe use the "Design Assistant" trough the API?

My expectation would be that the "Design Assistant" functionalities will be available trough the Inventor API, is this true?

I do not want to search trough the projects search paths with custom code.

 

The first function I want to use this for is:

When I loop trough the Structured BOM, I would like to open and print all drawings related to the components represented in this BOM view.

 

Thanks in advance.

ADN Support Specialist
xiaodong.liang
Posts: 1,276
Registered: ‎06-12-2011
Message 2 of 3 (180 Views)

Re: Finding "Where Used" or recreating the "Open Drawing" co

08-02-2012 01:38 AM in reply to: RPdAnjou

Could you have a look at this blog if it answered your question. It is written by Brian, our API expert .

 

http://modthemachine.typepad.com/my_weblog/2008/11/file-references-part-2.html



Xiaodong Liang
Developer Technical Services
Autodesk Developer Network

Contributor
RPdAnjou
Posts: 33
Registered: ‎06-06-2011
Message 3 of 3 (174 Views)

Re: Finding "Where Used" or recreating the "Open Drawing" co

08-02-2012 06:48 AM in reply to: RPdAnjou

That's something I did not find when searching for information about this topic.

 

While reading the blog:

At first I thought, hey, that's just like other solutions I found don the autodesk customization forum.

But then I also realized, when I open the drawing of a part, it does not have the same name!

 

We use Productstream Pro (where we can also find Where Used drawings, but that aside) and all documents get unique file names.

So a IDW will never have the same file name as the IPT or IAM.

Are you sure this function only checks file names? I think it also checks referenced files from all found IDW's.

 

Also, this is not a solution in VBA/.NET because this (Open Drawing) is not a API function, or is it?

 

Thanks for the info!

Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.