Skip to main content

I feel like this is a very simple question, but I have a checkbox at the end of a wizard I need to uncheck, but I would like the field to render unchecked without the user having to manually uncheck it.

Is there a basic rendering snippet I can use to uncheck the box?

For starters you could set the default value of the field to false. But assuming you want to use JavaScript, I would use a page load snippet, that runs when the page loads. Create a new snippet of type “inline” and add the following:


(function(skuid){&nbsp; &nbsp; var $ = skuid.$;<br>&nbsp; &nbsp; $(function(){<br>// The name of the Model your checkbox is in&nbsp;<br>&nbsp; &nbsp; &nbsp; &nbsp; var model = skuid.model.getModel('YourModel');<br>var row = model.getFirstRow();<br>&nbsp; &nbsp; &nbsp; &nbsp; model.updateRow(row,{<br>// replace YourFieldName with the API name of your checkbox<br>YourFieldName: false<br>});<br>&nbsp; &nbsp; });<br>})(skuid);&nbsp;

If you always want the checkbox to be unchecked by default, Moshe’s suggestion should work.

But if you only want to uncheck it when you get to a particular step (and otherwise have it remain checked) then you might want to build in the logic to un-check the checkbox into your Wizard Button.

Wizard Button can run a sequence of Actions — using Skuid’s “Action Framework”. Just change the Action Type of your button to be “Run Multiple Actions”. Add 2 Actions:

1. Update a field on row(s)
2. Navigate to Step

Action 1 can be used to uncheck your checkbox, and Action 2 will actually move the user to the step where the checkbox appears.

Here are screenshots of an example “Next Step” button i created in a wizard, where the next step is “step2”, but it can be whatever step you want to go to.





NOTE: if the “Navigate to Step” option does not show up for you, make sure you are on Skuid 5.13 or higher — if you’re not, head to skuidify.com/SkuidReleases and install the latest release.