Edit a card to have a pre-filled form and save it as new row/record

this is the scenario that is required for my app:

  1. User will search for ID
  2. User will press Edit to fetch all details of that ID
  3. User will do his changes
  4. User will save this changes BUT SAVES ALL AS NEW ROW/DATA

how can I achieve this. please help as our database is currently being compromised as the edit actually overwrites the existing data and not saving it as a new data.

Note: Add Data shows an empty form that the user needs to fill up everything. that is not what we need.

In the Card view, you have access to the actions and can replace them with a custom action.

Your custom action should run a LINKTOFORM() expression. This function opens a NEW record and allows you to preset the Form column values - which in your case will be copied from the current row.

In the Card View, there are several places where there is an “On Click” action property. You will simply need to replace one of these with your custom action. See explanation below.

Creating your custom Action

  • Replace “Existing form View” with name of your Form for the ID rows
  • For the column to b e preset, insert the table column name IN QUOTES and then follow with the table column name IN SQUARE BRACKETS. This will copy the value of that column from the current row into the new for under that column.

Adding Custom Action to Card View

The default action when clicking on the card is to go to the Detail View where you can then enter into Edit mode. If you wish for this to instead to use your Custom Action to go to a Form that adds a New row, then you will want to change the “On Click” property (shown below) from “Go to Details” to your custom action using the dropdown arrow.

If instead, you wish to change one of the 4 actions in the action bar, click that action in editor view (see bottom of image above), then change IT’S “On Click” action to your custom action.

3 Likes

Thank you John!

That was the best and most detailed tech support i have had. I was able to launch my app now. Thanks!

2 Likes

Just to make sure you are aware, when posting here in the Community it is usually other App Creators who are responding - paying it forward! Everyone is trying to help but sometimes we get it wrong - even those of us that have been using AppSheet for many years. This is usually due to a different way of thinking about the problem and mis-understanding the request. Keep posting, you’ll get the help you need.

2 Likes