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: 

simple question

3 REPLIES 3
Reply
Message 1 of 4
Nitro58
105 Views, 3 Replies

simple question

I created an assembly, a lot of parameters of parts are linked to an excel sheet (embed).

My question is : my assembly have a few sub-assemblies, and every sub-assembly has a drawing. How can I automatically update those drawings without having to open every sub-assembly to update it manually?

thanks

** I posted it last week, had no answer so posting again
3 REPLIES 3
Message 2 of 4
Nitro58
in reply to: Nitro58

ok, for now here are my ideas.. but I don't know which one is the best :

1 - create one main assy that contains all the sub-assys, I would have to Update only ONE assy before opening my drawings.

2 - I tried the "Task scheduler" , no succes, the sequential tasks were not working. (Update Assy, then Update Drawing), when I opened the drawing I still had a message it was not Updated.

3 - Maybe something is possible with Vault ?

4 - A Macro or VB, routine, something like ( Open assy, Update assy, Open drawing), for each sub-assy. But I don't know how to use Macros yet.

Well, your suggestions?

Thx again
Message 3 of 4
henrikubbe4438
in reply to: Nitro58

Hi Nitro58

What kind of update are you trying to do?
A Tools-Rebuild all should update all the subassemblies as well as the top one.

IV11, that is.

/Ub
Message 4 of 4
Nitro58
in reply to: Nitro58

I don't need a global update, juste an update. I don't see the Rebuild option in an idw.

Since I posted, I tried a few things and it is currently working ok, my macro is pretty simple, but I don't know anyone to help me, so I do my best.



Public Sub Open_update_save_close_open()

ThisApplication.Documents.Open ("T:\Inventor project\Projet_name\Project_assy.iam")
ThisApplication.ActiveDocument.Update
ThisApplication.ActiveDocument.Save
ThisApplication.ActiveDocument.Close

' Open the drawings needed
ThisApplication.Documents.Open ("T:\Inventor project\Project_name\DRAWINGS\Project_assy.idw")

' Remove all unattached dimensions

' Set a reference to the active drawing document
Dim oDoc As DrawingDocument
Set oDoc = ThisApplication.ActiveDocument

' Set a reference to the active sheet
Dim oSheet As Sheet
Set oSheet = oDoc.ActiveSheet

Dim oDrawingDim As DrawingDimension

' Iterate over all dimensions in the drawing
' and delete unattached (sick) dimensions.

For Each oDrawingDim In oSheet.DrawingDimensions
If oDrawingDim.Attached = False Then
Call oDrawingDim.Delete
End If
Next

End Sub



Then I repeat some commands to open a few more idw. The whole thing takes about 12 seconds, which is ok for me. Now, I want to save a copy of those drawings in another folder, because those base drawings can't be edited. I tried pack and go, but the link with the excel sheet was still there. Any suggestions?

(Inventor 2008 series. HP workstation xw4400, 3 GB RAM)

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

Post to forums  

Autodesk Design & Make Report