Community
Inventor Forum
Welcome to Autodesk’s Inventor Forums. Share your knowledge, ask questions, and explore popular Inventor topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Matching Title Block in Part Drawings to Assembly Drawing

14 REPLIES 14
SOLVED
Reply
Message 1 of 15
abreen
2403 Views, 14 Replies

Matching Title Block in Part Drawings to Assembly Drawing

I do a lot of work where I start with a full assembly drawing, then make more drawings for the individual parts. Is there a way to link the title block parameters in the part drawings to the title block in the full assembly drawing? The only way I found was to link the parts together and then grab the info for the drawings off of the parts, but if I'm implementing this in a template used by others I want them to still be able to just fill in the blank on the assembly drawing to make it work.

 

I was able to get iProperties to show parameter buttons, but I haven't seen any way to link to other files or anything like that. Thanks in advance.

14 REPLIES 14
Message 2 of 15
Curtis_Waguespack
in reply to: abreen

Hi abreen,

 

I think the best way to do this would be to create a view of the assembly on the sheet first before placing the view(s) of the part model, since the title block reads the iProeprty information from the first referenced model.

 

You can place the assembly view out side of the sheet border, to ensure that it does not impact the print and/or right-click on the assembly view and choose Suppress.

 

Note too that you might go to this IdeaStation idea, and add your vote, and/or additional comments to support improvement for your work flow in Inventor:

http://forums.autodesk.com/t5/Inventor-IdeaStation/Improve-Leader-Text-to-Pull-Subassembly-iProperti...

 

I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com

 

Message 3 of 15
mcgyvr
in reply to: Curtis_Waguespack

Not enough information to give a proper answer IMO...

By "more drawings" to you actually mean "more sheets" or more IDW files..

 

But I also feel that their should be NO connection between any drawings really.. Each part and each assembly should have its own idw file with no ties to each other..

I guess that comes from my background working on actual products where parts are commonly reused. and not a "1 off project by project" type of thing.. I reuse hundreds of parts on hundreds of different assemblies and thus a reference to any specific part or assembly IDW is just stupid/bad practice 

 

 

 



-------------------------------------------------------------------------------------------
Inventor 2023 - Dell Precision 5570

Did you find this reply helpful ? If so please use the Accept Solution button below.
Maybe buy me a beer through Venmo @mcgyvr1269
Message 4 of 15
abreen
in reply to: Curtis_Waguespack

Thanks, Curtis.

 

Unfortunately, I need a solution that I can implement after the fact. We have 60 templates or so, each with its own set of detail drawings and I can't go remaking these anytime soon.

 

Also, we currently change parameters like CUSTOMER and AUTHOR directly in the drawing, rather than "doing it right" and having the appropriate metadata in the part files, and I can't change that paradigm.

 

I might give a go at writing some iLogic to do this for me, but I'm not sure I'm handy enough with it to automate this with reasonable ROI. Does anybody know how how to use expressions in iProperties?

Message 5 of 15
mcgyvr
in reply to: abreen

Why don't you give some specifics on exactly what you are trying to do?

 



-------------------------------------------------------------------------------------------
Inventor 2023 - Dell Precision 5570

Did you find this reply helpful ? If so please use the Accept Solution button below.
Maybe buy me a beer through Venmo @mcgyvr1269
Message 6 of 15
abreen
in reply to: mcgyvr

Thanks for the reply, mcgyvr.

 

I believe that if the drawings were all sheets of the same .idw file, they would automatically share the iProperty data that fills the title blocks. There are individual files here, and that's the arrangement I need to work with.

 

I totally agree that it would generally be a dumb plan to link to standard parts, however we operate as a job shop where every order gets a fresh set of models and drawings based on a Copy Design of a template. So, this arrangement does not lead to any link problems. Other than making the links at all, so far.

Message 7 of 15
abreen
in reply to: mcgyvr

At least for the moment, all I am trying to do is make the "Company" iProperty fill in for all the part drawings when a user fills it in with the customer's name on the assembly drawing.

Message 8 of 15
Curtis_Waguespack
in reply to: abreen


@abreen wrote:
... I might give a go at writing some iLogic to do this for me, but I'm not sure I'm handy enough with it to automate this with reasonable ROI. Does anybody know how how to use expressions in iProperties?

hmmm, I like this idea. Give me a bit and I'll see if I can throw something together this afternoon.

 

I'm thinking:

* run the rule from the IDW

* check the IDW iProperties for a assembly file path

* if the path is blank, then present a dailog box to browse for the assembly file

* copy the iProperties from the selected assembly to the iProperties of the IDW file

* write the assembly file path to the IDW iProperties

 

Or

* run the rule from assembly

* for each component in the assembly, copy the assembly iProperties to the part iProperties ( or to the custom part iProperties)

 

Does one of those ideas sound close to what you're after?

 

I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com

 

Message 9 of 15
mcgyvr
in reply to: abreen

So your "top level" assembly iam file has a "company" iproperty filled in but NONE of the parts do and their company iproperties are just blank..

 

Using whats built into Inventor you could just use the "Copy Design Properties" function in the design assistant to quickly fill in the company field on all parts.

Its only a few mouse clicks and would solve the problem. 

Just open the top level assembly. Go to File..manage..design assistant... When that opens go to... tools..copy design properties.

Then just check the company property in the "copy from" side and then click the "all open file" on the "copy to" section and voila..like magic all the parts in that assembly would get their company iprop filled out..

 

Not the "Easy button" but the "Easy few clicks"



-------------------------------------------------------------------------------------------
Inventor 2023 - Dell Precision 5570

Did you find this reply helpful ? If so please use the Accept Solution button below.
Maybe buy me a beer through Venmo @mcgyvr1269
Message 10 of 15
abreen
in reply to: Curtis_Waguespack

I like your ideas, Curtis.

 

If it was just me using this, then either of those workflows would be great. But, an important aspect of this project is that it has to work for all of our drafters, and really that means I can't add any steps to their routine at all, including going back to update the .iam or .ipt files. It'll have to run itself and be totally transparent to the user, which limits my options.

 

The way I was thinking this could work leverages our file structure, where the assembly has a 5-digit serial number (12345.iam, 12345.idw) and the parts just have letters appended (12345-A.ipt, 12345-A.idw). I should be able to add code that autoruns on file open to each part .idw file. This code would take the first five letters of the filename, add .idw, and copy the "Company" iProperty from that file to the current file.

Message 11 of 15
abreen
in reply to: mcgyvr

mcgyvr, that's a pretty great tool that I didn't even know existed, thanks. My solution has to have complete transparency to the user though. Plus, it's already easy enough to fill in those fields with good ol' ctrl+V. I'm trying to completely eliminate this step, more to reduce user error than for speed, and to learn a little more about IV in the process.

Message 12 of 15
Curtis_Waguespack
in reply to: abreen

Hi abreen,

 

Here's a quick iLogic rule to be run in the drawing. It will look at the assembly file based on the drawing file name, and then write the Title, Company and Project iProperties from the assembly to the drawing.

 

There is likely other ways to do this, so if this doesn't work for you post back.

 

I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com

 

'change active document extension to iam, as a string
'example: running this rule in a file called 12345.idw will return 12345.iam
'this assumes the path and file name of the assembly are the same as the drawing
sDoc = ThisDoc.ChangeExtension(".iam")

'open the assembly  file, false opens the file without generating the graphics
invDoc = ThisApplication.Documents.Open(sDoc, False)

'define the property sets
'note: see http://www.autodesk.com/us/community/mfg/Part_4.pdf for list of all property sets
'define the iproperties Summary property set
Dim invSumProperties As PropertySet
invSumProperties = invDoc.PropertySets.Item("Inventor Summary Information")

'define the iproperties Document Summary property set
Dim invDocSumProperties As PropertySet
invDocSumProperties = invDoc.PropertySets.Item("Inventor Document Summary Information")

'define the iproperties design tracking property set
Dim invDTProperties As PropertySet        
invDTProperties = invDoc.PropertySets.Item("Design Tracking Properties")

'get the iProperties from the assembly
'get the Title  from the assembly
oTitle = invSumProperties.Item("Title").Value
'get the company name from the assembly
oCompany = invDocSumProperties.Item("Company").Value
'get the project from the assembly
oProject= invDTProperties.Item("Project").Value

'write the assembly iProperty values to the drawing iProperties
iProperties.Value("Summary", "Title") = oTitle
iProperties.Value("Summary", "Company") = oCompany
iProperties.Value("Project", "Project") = oProject

'update the drawing file
InventorVb.DocumentUpdate()

'close the assembly file
invDoc.Close

 

Message 13 of 15
abreen
in reply to: Curtis_Waguespack

Thanks a lot for the help!

 

I had gotten most of the way there, but I was having trouble actually getting the iProperties read from the assembly drawing. Your code copies properties from the assembly model to the assembly drawing, it was easy to adapt it to copy from the assembly drawing to the part drawing (or current drawing). Here's my final code:

 

Sub Main()
	On Error Goto ErrSilent 'ninja code is silent on failure

	If iProperties.Value("Summary","Company") = "CUSTOMER"
		Dim assy_idw = ThisDoc.Path & "\" & Left(ThisDoc.FileName,5) & ".idw"
		invDoc = ThisApplication.Documents.Open(assy_idw, False)

'define the property sets 'note: see http://www.autodesk.com/us/community/mfg/Part_4.pdf for list of all property sets 'define the iproperties Summary property set Dim invSumProperties As PropertySet invSumProperties = invDoc.PropertySets.Item("Inventor Summary Information") 'define the iproperties Document Summary property set Dim invDocSumProperties As PropertySet invDocSumProperties = invDoc.PropertySets.Item("Inventor Document Summary Information") 'define the iproperties design tracking property set Dim invDTProperties As PropertySet invDTProperties = invDoc.PropertySets.Item("Design Tracking Properties") oAuthor = invSumProperties.Item("Author").Value oCompany = invDocSumProperties.Item("Company").Value 'write the assembly drawing iProperty values to the part drawing iProperties iProperties.Value("Summary", "Author") = oAuthor iProperties.Value("Summary", "Company") = oCompany MsgBox("ran") InventorVb.DocumentUpdate() 'invDoc.Close Else Return End If ErrSilent: End Sub

 

Note that I commented out document close. I didn't want problems with the file closing when the user wants it to stay open. If the file wasn't already open, it doesn't show up because of the "False" in file open... does it stay open, taking up memory and causing potential vault issues? What I really wanted to do was have the script check if the source file is open and leave it as it was found, but I couldn't figure out how to check that.

Message 14 of 15

HI Curtis,

Do you have way to make the code work with custom iproperties from the assembly to drawing. I found it works well with the standard properties but runs into issues on custom properties.

Thanks

Kurt

Message 15 of 15

Hi kurtTTA2U,

 

Here is a version that looks at the custom iproperty set as well.

 

I hope this helps.
Best of luck to you in all of your Inventor pursuits,
Curtis
http://inventortrenches.blogspot.com

 

'change active document extension to iam, as a string
'example: running this rule in a file called 12345.idw will return 12345.iam
'this assumes the path and file name of the assembly are the same as the drawing
sDoc = ThisDoc.ChangeExtension(".iam")

'open the assembly  file, false opens the file without generating the graphics
invDoc = ThisApplication.Documents.Open(sDoc, False) 

'define the property sets
'note: see http://www.autodesk.com/us/community/mfg/Part_4.pdf for list of all property sets
'define the iproperties Summary property set
Dim invSumProperties As PropertySet
invSumProperties = invDoc.PropertySets.Item("Inventor Summary Information")

'define the iproperties Document Summary property set
Dim invDocSumProperties As PropertySet
invDocSumProperties = invDoc.PropertySets.Item("Inventor Document Summary Information")

'define the iproperties design tracking property set
Dim invDTProperties As PropertySet        
invDTProperties = invDoc.PropertySets.Item("Design Tracking Properties")

'define the iproperties design tracking property set
Dim oCustomPropertySet As PropertySet        
oCustomPropertySet = invDoc.PropertySets.Item("Inventor User Defined Properties")

'get the iProperties from the assembly 
'get the Title  from the assembly
oTitle = invSumProperties.Item("Title").Value 
'get the company name from the assembly
oCompany = invDocSumProperties.Item("Company").Value 
'get the project from the assembly
oProject= invDTProperties.Item("Project").Value 

'write the assembly iProperty values to the drawing iProperties
iProperties.Value("Summary", "Title") = oTitle
iProperties.Value("Summary", "Company") = oCompany 
iProperties.Value("Project", "Project") = oProject

Try 
'get the Custom iprop from the assembly
oLocation = oCustomPropertySet.Item("LOCATION").Value 
iProperties.Value("Custom", "LOCATION") = oLocation
Catch
End Try

'update the drawing file
InventorVb.DocumentUpdate()

'close the assembly file
invDoc.Close

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report