Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
Anonymous
515 Views, 2 Replies

how to get filename without extention

Hi there,

 

Using the following code to create a filename when I use my macro to create a DXF of a flat pattern in my sheet metal part:

 

Dim strPath As String
strPath = oPartDoc.FullFileName
Dim oDXFfileNAME As String
oDXFfileNAME = strPath & ".dxf"

 

Dim oDataIO As DataIO
Set oDataIO = oPartDoc.ComponentDefinition.DataIO

 

  oDataIO.WriteDataToFile sOut, oDXFfileNAME

 

 

My files are now saved as fullfilename.ipt.dxf

 

How do I get rid of the itp part

So how do I get the full name of the file in strPath without the ".ipt"

 

Thanks in advance!