Friday, November 16, 2012

Multiple ways to export your data in ruby on rails

1. Prompting and letting user save csv in a particular folder:

Export excel from Rails application - User gets a link on view and when user clicks on that link a prompt comes asking user to save the exported excel on clients computer at desired location. In this case, you can create excel view and perform view formatting as we do with html page.

URL of blog - prompting-and-letting-user-save-csv-in-particular-folder


2. Saving the csv at a particular pre-defined folder:

Export csv at a particular pre-defined folder specified in rails application: User gets a link on view and when user clicks on that link user is not asked about the location for saving the csv, csv is exported and saved at pre-defined location. In this case, you cannot create excel view.

URL of blog - export-csv-at-particular-pre-defined-folder

No comments:

Post a Comment