Warning!
This is a legacy document. The features described below are only usable within the classic-generation environment.
Currently, Betty Blocks offers faster and more advanced options that are available in next-gen. Before you start working on some new features in your application, consider doing it using the next-gen version. Good luck!
Betty Blocks has its own export function inside the platform. This export function is active on every grid. It enables you to export your data from a grid to an Excel or CSV file within a few clicks.
Setting up export configurations
Go to the Back Office page by clicking on the Back Office icon in the Builder Bar.
Select a grid from the sidebar that you want to make an export of.
Click on the export icon in the header of the grid view, a menu will slide down. To start a new export, click on the Compose export button.
The Compose an export definition modal will pop up. Within this modal, you can choose which properties you want to include within your export file. The properties that will be included in your export file will be shown on the right side of the modal. A few properties will already be selected, these are the properties that are present within the grid you are exporting from.
It is possible to change the name of the header of a property by clicking on the name of a selected property. The name will change into a text field where it can be edited for the export file.
By clicking on the gear icon on the bottom left of the modal a few more settings will pop up. If you want to know more about each setting within the Compose an export definition you can take a look at this article: Export Reference
When you are done setting up everything you can start the export by clicking on the Export button. It is also possible to save the export by clicking on the Save and export button, this will save time when you need to do the same export multiple times.
After the export is executed a notification will pop up, this means that the export is ready to download. The export file can be downloaded in the download tab in the bottom right corner of the Sidebar.
Click on the download icon of the export file to download the file.
If the export settings were saved then they can be re-used. This can be done by clicking on the export icon in the header of the grid view and choosing the saved export settings. This way the export will be executed immediately.
Using exporting with actions
Actions can also be used to make exports. This way it's possible to automize the exporting. To be able to create an export step there needs to be a saved export definition for that specific grid.
Go to your Actions by clicking on the Actions icon in the Builder Bar.
Create a new action by clicking on the New button on the upper left side of the screen.
Choose a description and a model for the action. Note that a collection should be used in the action step to export the data. This collection can be created in the variables section of the action.
Click on the Save button if you are done with setting up the action.
Now create a new action step for the action by clicking on the plus icon inside of the action.
A new action step will be created. This step should be set to an Export step. This can be done in the Kind drop-down. By doing this the form will get the right format to set up the export.
Now we have to choose a grid that will reference our export, in this drop-down all the grids are displayed. Choose the grid of the model that you want to make an export of.
Select the collection containing the export data. By clicking on the Click to set button the Variables browser will pop up, in this browser you can choose a collection for your export.
Choose the export definition that you want to use for the export. If none can be chosen, make sure to create a definition first before proceeding.
If you are done with setting up the action step you can click the Save button to save it.
You can continue with creating your action to add specific rules to the execution of the import. If you are done with creating your action you can press the Save button to save it.