Click here to Skip to main content
15,942,847 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I'm trying to export contents of a datgridview to excel via c# windows application . When i click Export button , i want the open , save , cancel dialog box to open so that if user clicks open ,user can directly view the contents of exported data without saving it , or if user clicks save then file can be saved . i found code to export file show save/save as dialog , and also code to open an already saved file . But my requirement is different. Please help..Thanks.
Posted

So, just to clarify....are you saying that you want a dialog similar to Firefoxes or IE's when you click a link to a file and it has two radio buttons...one for Open file and one for Save file?

There may be controls out there to do that, but I'm not familiar with them. But, it wouldn't be that difficult to implement.

If you're wanting to know how to choose which program to use, this article (Get Registered File Types and Their Associated Icons in C#[^]) shows you how.

It may be out there, but I don't think you're going to find exactly what you're looking for. Just create it yourself!
 
Share this answer
 
Yeah , I'm trying to implement the dialog similar to IE's . It seems like this requirement can be implemented very easily in web applications , but for windows application it isn't straightforward. I guess my next step would be to create my own dialog box. Thanks for the reply.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900