I'm using the featureTable dijit in my application. I am able to populate the table based on different featureLayers in the map. I would like to be able to export the table to a CSV file the user can download. The number of features in table can be any where from less than 10 to upwards of 10,000. Is there any samples or known ways to export the featureTable to CSV? I have tried several things but have been unsuccessful.
Basically, you need to use "esri/tasks/Geoprocessor". which means you have to create your own geoprocessing tool and then publish as gp service.
For more information, you can take a look about this online documentation about "geoprocessing specifically in ArcGIS Server 10.2 version" http://resources.arcgis.com/en/help/main/10.2/index.html#//002s00000002000000
Hope this can help.
You have to write code to implement this new function. Currently FeatureTable widget doesn't have csv export function.
Essentially, you need to get all the data that loaded in dgrid and export to csv file.
Yes that is exactly what I'm attempting to do. I was aware the featureTable does not have the export capability (would be a fantastic addition) and that I would need to write a custom piece. That is what my original question was for. I will look at the sample in the link you posted to see if that is something that can work in my application.
In the mean time, has anyone been able to figure out a way to do this?
Only exports what the table has downloaded though and only the raw data. Could tweak to export using column data probably.
Hi Rene Rubalcava this sample that you put together is precisely what I need but it doesn't seem to work for me :( I simply took it exactly as-is and put it in a HTML...no error in my console but no download either...
Thanks guys! I knew there had to be a simplier way of doing this. I had come up with a solution but it was a bit hacky, this is much cleaner. I will give it a try in my app.
Yue, you said to view the live demo in Chrome. Why is that? Will the functionality not work in other browsers or is it just jsbin?