Sign In| Join
Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Jan 22, 2013 06:05 PM by nicklibee
Member
650 Points
692 Posts
Jan 22, 2013 06:15 AM|LINK
Dear all,
I have a excel file named a.xlsx and it is stored in a webfolder called "filetodownload"
On my asp.net application, i have a button.
On click of the button i want to download a.xlsx file and store it in client machine folder named c:\details.
How can i do this?
Thanks
Nick
72 Points
11 Posts
Jan 22, 2013 06:54 AM|LINK
Hello Nick, If you want to download the file than you can add just pass the URL and name of your file so it will ask for download and it will open save as dialog and you can save it as you want.
<asp:HyperLink ID="lnkDownloadCSVFile" runat="server" NavigateUrl="~/Template.xlsx" Text="Download">
If you will have fix folder than you need to check directory on client system and after that you can save. I think if you will ask for user for save location than it will be better to manage. Let me know if you have any query or you need any more.
Jan 22, 2013 06:05 PM|LINK
thanks , u r correct.
users wanted to store the file in their client machine. i did that part and its working.
my excel sheet is macro enabled and i cant write the data to .xlsm file.
how can i do that??? if i convert it to .xls file its working fine.
thanks
nick
nicklibee
Member
650 Points
692 Posts
download the excel file from the webfolder and store it in client machine
Jan 22, 2013 06:15 AM|LINK
Dear all,
I have a excel file named a.xlsx and it is stored in a webfolder called "filetodownload"
On my asp.net application, i have a button.
On click of the button i want to download a.xlsx file and store it in client machine folder named c:\details.
How can i do this?
Thanks
Nick
nhkariya
Member
72 Points
11 Posts
Re: download the excel file from the webfolder and store it in client machine
Jan 22, 2013 06:54 AM|LINK
Hello Nick,
If you want to download the file than you can add just pass the URL and name of your file so it will ask for download and it will open save as dialog and you can save it as you want.
If you will have fix folder than you need to check directory on client system and after that you can save.
I think if you will ask for user for save location than it will be better to manage.
Let me know if you have any query or you need any more.
Please remember to click “Mark as Answer” on the post that helps you
nicklibee
Member
650 Points
692 Posts
Re: download the excel file from the webfolder and store it in client machine
Jan 22, 2013 06:05 PM|LINK
thanks , u r correct.
users wanted to store the file in their client machine. i did that part and its working.
my excel sheet is macro enabled and i cant write the data to .xlsm file.
how can i do that??? if i convert it to .xls file its working fine.
thanks
nick