SaveAs Method [Visio 2003 SDK Documentation]
Saves a document with a file name.
object**.SaveAs**FileName
object Required. An expression that returns a Document object.
FileName Required String. The file name for the document.
Version added
2.0
Remarks
The SaveAs method can accept drive names that use the universal naming convention (UNC), for example, \\corporation\marketing.
Beginning with Visio 2002, you can save your drawing as an XML drawing (.vdx), an XML stencil (.vsx), or an XML template (.vtx).
Example
This Microsoft Visual Basic for Applications (VBA) macro shows how to use the SaveAs method. Before running this macro, change path to the location where you want to save the drawing, and change filename to the name you'd like to assign the file.
Public Sub SaveAs_Example()
'Use the SaveAs method to save a document for the first time.
ThisDocument.SaveAs "path\filename.vsd"
End Sub
Applies to | Document object
See Also | Save method | SaveAsEx method