.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Question about SaveFileDialog

3 REPLIES 3
Reply
Message 1 of 4
simonkx
813 Views, 3 Replies

Question about SaveFileDialog

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!
3 REPLIES 3
Message 2 of 4
simonkx
in reply to: simonkx

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
Message 3 of 4
simonkx
in reply to: simonkx

The problem has been resolved!
Message 4 of 4
ampplee
in reply to: simonkx

Could you clue me in on your resolution?

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost