Update assembly

Update assembly

Anonymous
Not applicable
352 Views
1 Reply
Message 1 of 2

Update assembly

Anonymous
Not applicable
Hi,

I ‘m trying to update the changes I’ve made in a part of an assembly, save this assembly and then open the drawing related to the assembly. The problem is that the saved assembly isn’t the updated version, but just the old one. It seems that before the entire assembly is updated, it’s already saved. Is there a possibility to delay the saving until the updating is done?

Thanks,

Peter

Ps. Here is the code:

‘deleting some features of the part
For Each oFeat In oOcc1.Definition.Features
If oFeat.Name = "Dim" & i & "_FU" Then
oFeat.Delete
End If
Next

‘updating the assembly and saving it
oAssDoc.Update
oApp.SilentOperation = True
oAssDoc.Save
oApp.SilentOperation = False

‘opening the drawing related to the assembly
Set oDrwDoc = oApp.Documents.Open(sPath & "workspace.idw", True)
0 Likes
353 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable
Hi Peter,

 

Something to try....    you may want
to try calling rebuild too before calling save.

 

Regards

 

Peter Heald

 


style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
Hi,

I ‘m trying to update the changes I’ve made in a part of an assembly, save
this assembly and then open the drawing related to the assembly. The problem
is that the saved assembly isn’t the updated version, but just the old one. It
seems that before the entire assembly is updated, it’s already saved. Is there
a possibility to delay the saving until the updating is done?

Thanks,

Peter

Ps. Here is the code:

‘deleting some features of the part
For Each oFeat In
oOcc1.Definition.Features

                If
oFeat.Name = "Dim" & i & "_FU" Then

                oFeat.Delete

                End
If
Next

‘updating the assembly and saving it
oAssDoc.Update

oApp.SilentOperation = True
oAssDoc.Save
oApp.SilentOperation =
False

‘opening the drawing related to the assembly
Set oDrwDoc =
oApp.Documents.Open(sPath & "workspace.idw",
True)

0 Likes