Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
WCrihfield
in reply to: ngnam1988

Here are some lines of code that you can use for that sort of thing.

Dim oDoc As Document = ThisApplication.ActiveDocument
Dim oPath As String = System.IO.Path.GetDirectoryName(oDoc.FullFileName)
Dim oName As String = System.IO.Path.GetFileNameWithoutExtension(oDoc.FullFileName)
Dim oNameAndExt As String = System.IO.Path.GetFileName(oDoc.FullFileName)
Dim oExt As String = System.IO.Path.GetExtension(oDoc.FullFileName)

If this solved your problem, or answered your question, please click ACCEPT SOLUTION .
Or, if this helped you, please click (LIKE or KUDOS) :thumbs_up:.

 

Wesley Crihfield

EESignature

(Not an Autodesk Employee)