Bulk reset a canvas column using a master template page

Team,

I have a table “Project Plan” with a canvas column “Details” that has a default set for the ‘value for new rows’ option. This value is a “Project Plan Template” page. I’m trying to create a canvas-level button with RunActions/ModifyRows to reset the column values after I update the “Project Plan Template”. Initially, I was thinking something like the formula below could work but how do I reference the “Project Plan Template” page?

RunActions(
ModifyRows([Project Plan], [Project Plan].Details, “Project Plan Template”)
)

Thank you for the help!

Hey @Amish_Noorali ,

You have to use a small workaround to accomplish this.

You cannot get a reference to your template page directly, but if you type

DuplicatePage(

you can then start typing the name of your template page.
You will end up with something like this:

DuplicatePage([template page])

At this point, in the formula editor, it looks like this:


Now that you have an object (the pill with the name of the template page) you can edit your formula and delete the parenthesis and the formula DuplicatePage:
image
Now you have a formula that does exactly what you want.
It won’t run particularly fast, if you have a couple hundred rows it will take some time, but activate your formula when you go for lunch and when you get back, it’s done :hamburger:.

It’s not complicated, once you know :slight_smile:

3 Likes

Thank you for making me aware of the duplicate page function. Performance is a big deal since we’ll be dealing with thousands of rows. Your approach works but it also creates a random copy at the root level.

Hello @Amish_Noorali ,

You have to make sure you edit the DuplicetePage() function: only the page object needs te be there, not the function. You only use the function in order to create the template page reference.
If you to that properly, no extra page copies should be created at the root level.

Please let me know of that works.

I understand what you are saying about performance, but I guess you would not do this on a daily basis? It works for me.

Greetings,
Joost

1 Like

Ah - I see what you mean. I misread - I was including the DuplicatePage function. This works! Thanks for the assist.

2 Likes

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.