Good afternoon everyone!
How can I copy a drawing file in one folder and save it in another folder?
Dim Filedata As String Dim Filework As String Filedata = ThisDoc.Path + "\DATA\Drawing_1.idw" Filework = ThisDoc.Path + "\Drawing_1.idw" Select Case OPTION_C Case "OPTION-C0" InventorVb.Application.FileManager.DeleteFile(Filework) Case "OPTION-C1" ThisApplication.Documents.Open(Filedata, False) ThisDoc.Document.SaveAs(Filework, True) ThisDoc.Document.Close(True) Case Else 'MessageBox.Show("***", "Title") End Select
Solved! Go to Solution.
Solved by smart-cad. Go to Solution.
Solved by WCrihfield. Go to Solution.
Solved by WCrihfield. Go to Solution.
You can use the following method:
Dim oOldNamePath As String = "C:\Temp\MyFolder\MyDrawing.idw"
Dim oNewNamePath As String = "C:\Temp\MyDrawing.idw"
System.IO.File.Copy(oOldNamePath, oNewNamePath, False)
If this solved your problem, or answered your question, please click ACCEPT SOLUTION.
Or, if this helped you, please click (LIKE or KUDOS) 👍.
If you want and have time, I would appreciate your Vote(s) for My IDEAS :light_bulb:or you can Explore My CONTRIBUTIONS
Wesley Crihfield
(Not an Autodesk Employee)
Here's another similar method that can be used in the same way in iLogic (vb.net):
Wesley Crihfield
(Not an Autodesk Employee)
I love you all. I love this site. It's so inspiring. Thanks for being here guys.
Can't find what you're looking for? Ask the community or share your knowledge.