For the latest documentation on Visual Studio 2017, see. By default, users can export to Microsoft Office Excel any list of data that appears in a screen. Then, users can create charts, reports, and PivotTables by using features in Excel. If you want to prevent users from exporting data to Excel, you can disable this feature in the Screen Designer of your project. Note Export to Excel functionality is only enabled for desktop applications. Web applications cannot access local resources or files due to security restrictions.
Users of your application can export data to Excel by clicking the Export to Excel button that appears in a screen. Users can only export collections of data. Therefore, the Export to Excel button appears above collection of data records only (For example: A customer List or products GridView). The Export to Excel button does not appear above areas in the screen that display the details of a data item. When users click Export to Excel, the application opens an Excel worksheet, and then populates the worksheet by using data from the collection that appears on the screen. Data that does not appear on the screen is not exported.