Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations KootK on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Save as flat... (DXF)

Status
Not open for further replies.

ailuJ

Computer
Oct 11, 2002
4
Hi,

I'm trying to obtain the DXF file of a sheet metal part, the flattened DXF of the sheet metal part, but... it only runs if previously I have do it interactively "File//Save as flat...// select a planar face or edge // and save as DXF file"

In the program I use the SaveAs method, an I give it the name of de file with the DXF extension, perhaps I have to do something with the model before saving it as DXF file?

thanks in advance
 
Replies continue below

Recommended for you

I have solved (accidentally) my problem, or I think that I had do.

This is my old code: (it doesn't work)

Code:
    Dim objFoldedDoc As Object
    Set objFoldedDoc = objApp.ActiveDocument

    Call objFoldedDoc.SaveAs(NewName:="E:\Documentation\Fig_SolidEdge\PRU-DXF-11.DXF")

And this is my new code: (works perfectly)

Code:
    Dim objFoldedDoc As SolidEdgePart.SheetMetalDocument
    Dim cActDocType As DocumentTypeConstants
    cActDocType = objApp.ActiveDocumentType
    If cActDocType = igSheetMetalDocument Then
        Set objFoldedDoc = objApp.ActiveDocument
    Else
        Exit Sub
    End If

    Call objFoldedDoc.SaveAs(NewName:="E:\Documentation\Fig_SolidEdge\PRU-DXF-11.DXF")
So... the objFoldedDoc variable seems to have to be igSheetMetalDocument type.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor