Sorry, I apologize, but i wrote the post in a hurry after searching in thee discussion group and on the web for a while!
what follows is a snippet of the program that saves the drawing, and it works perfect with "DwgVersion.Current"
Private Sub SalvaToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles SalvaMenuItem.Click
Dim myDB As DatabaseServices.Database
Dim myDWG As ApplicationServices.Document
' Connect to current Active Drawing
myDWG = ApplicationServices.Application.DocumentManager.MdiActiveDocument
myDB = myDWG.Database
Dim myEd As EditorInput.Editor
Dim myPFR As EditorInput.PromptFileNameResult
Dim myPSO As New EditorInput.PromptSaveFileOptions("Select a file:")
myEd = myDWG.Editor
' Save File dialog setup
With myPSO
.InitialDirectory = My.Computer.FileSystem.CurrentDirectory
.Filter = "AutoCAD DWG Files|*.dwg"
End With
' Show Save Dialog
myPFR = myEd.GetFileNameForSave(myPSO)
'this line of code works!
'myDB.SaveAs(myDWG.Name, DwgVersion.Current) <---- works fine
'THIS IS THE LINE THAT BRINGS THE FOLLOWING ERROR: eInvalidDwgVersion
myDB.SaveAs(myPFR.StringResult, DwgVersion.AC1008) <---- ERROR: eInvalidDwgVersion
End Sub
as you can see I'm not doing nothing special, just used one of the string that VS 2005 gives me in an AutoCad manged program.
As I said in my previous post I'm in the need to save my current document in different versions (used by other software) AutoCAD 2000-2004.dwg and AutoCAD 2000-2004.dxf.
Acutally if you can tell me how to translate the online guide AcApDocument::SaveFormat Enum in the strings returned in VisualStudio it would be great.
Thanks in advance
René