How do I refresh the data on a device? | Aquro Help Center

To refresh the data on a device and re-synchronize with data in the Aquro cloud, you should use the Visual Coding Script and use the Data.Col.Sync coding block.

This is done via following these steps:

  1. Add a ui.button to your page to serve as your "referesh button" and edit the Click event Visual Coding Script
  2. Add a Data.Col.Sync coding block to your workflow
  3. Connect the Start node to the Data.Col.Sync coding block
  4. Map the collection you would like to synchronize with the Collection input parameter on the block
  5. Click Save to close the block's Configuration window
  6. Add a Page.Load block to your workflow
  7. Connect the outlet Done from your Data.Col.Sync block to your Page.Load block 
  8. Map the current page to the Page input parameter on the block 
  9. Click Save to close the block Configuration window
  10. Click on Save to save your Visual Coding Script

In step 2 - 5 you will add a call to the block that will refresh the data on the device with the updated data in the cloud. In step 6-9 you will add a call to the Page.Load block to refresh the current page with the loaded data.

Depending on your choice you may like to automatically refresh the data each time the app loads. To accomplish this, you should create a separate page that will execute the refresh script and then load the Home page after the data is successfully refreshed.