Question about SaveFileDialog

Question about SaveFileDialog

Anonymous
Not applicable
952 Views
3 Replies
Message 1 of 4

Question about SaveFileDialog

Anonymous
Not applicable
Hi,
I want to invoke the savefiledialog to save a dwg-file,and my code is like this:

Autodesk.AutoCAD.Windows.SaveFileDialog sfd = new Autodesk.AutoCAD.Windows.SaveFileDialog("File save as","Drawing1.dwg","dwg","saving file",Autodesk.AutoCAD.Windows..SaveFileDialog.SaveFileDialogFlags.DefaultIsFolder);
sfd.ShowDialog();

But I found nothing where the file had been saved.Is there anything wrong with the code?Are there some examples about the savefiledialog with C#?

Thanks for your help!
0 Likes
953 Views
3 Replies
Replies (3)
Message 2 of 4

Anonymous
Not applicable
I have changed the code like this:
Autodesk.AutoCAD.Windows.SaveFileDialog sfd = new Autodesk.AutoCAD.Windows.SaveFileDialog("File save as","Drawing1.dwg","dwg","saving file",Autodesk.AutoCAD.Windows.SaveFileDialog.SaveFileDialogFlags.DefaultIsFol der);

if( sfd.ShowDialog() == DialogResult.OK)
db.Saveas(sfd.filename,DwgVersion.Current);

but it's still wrong.

someone could show me any examples of C#?
Thanks
0 Likes
Message 3 of 4

Anonymous
Not applicable
The problem has been resolved!
0 Likes
Message 4 of 4

Anonymous
Not applicable
Could you clue me in on your resolution?
0 Likes