Resolve Drawing View Links

Resolve Drawing View Links

ndillner343SKL
Enthusiast Enthusiast
8,736 Views
1 Reply
Message 1 of 2

Resolve Drawing View Links

ndillner343SKL
Enthusiast
Enthusiast

Hello,

 

I'm trying to take all the different VIEW's on a drawing. Look at what there OldFileName is (the link that is un-resolved). And resolve the different VIEW's with a NewFileName.

 

Thank you for your time!

0 Likes
8,737 Views
1 Reply
Reply (1)
Message 2 of 2

Curtis_Waguespack
Consultant
Consultant

Hi @ndillner343SKL 

 

This doesn't look at the drawing views, but it replaces all of the references to the old file with the new one.

 

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

 

sOldName = "C:\Temp\111.ipt"
sNewName = "C:\Temp\222.ipt"

oDrawDoc = ThisDrawing.Document Try oFDs = oDrawDoc.File.ReferencedFileDescriptors Catch ex As Exception 'Logger.Info(ex.Message) Exit Sub End Try Dim oFD As FileDescriptor For Each oFD In oFDs Try If oFD.FullFileName = sOldName oFD.ReplaceReference(sNewName) End If Catch ex As Exception 'Logger.Info(ex.Message) End Try Next

 

EESignature