I have a job application form which collects personal details etc. When a new row is added on Submit I have two default fields I wanted populated 1) Application Status = New Applicant 2) Pay rate = 27
These fields are then edited later by a different app to change values in some cases.
I tried adding using a thread I found but it displays the fields to the user with a (+) sign next to them a values populated. No good. Don’t want user to see the fields.
Also looked at setting a default value for the field, but visibility doesn’t allow the fields not to be seen no matter what I select as options.
I am sure its possible. Just don’t know the different options well enough yet.
You should be able to use a Set Column Values as an On Submit action with your form.
I’m hesitant to use 'On Submit for anything, especially a set column action. If I were to do it, I would either create template columns with those default values in either the user profile table (if a user is signed in and user profiles are enabled), or create those template columns in the parent table of the tab that contains the form button. Then it’s as simple as adding user profile components or column value components into the form. They are not visible on the form screen, but they pass the value through to the form result table automatically.
I kind of agree, but I’m fairly certain I’ve seen others (including Bob?) talk about doing this on several occasions, so I guess on that basis I’ve always assumed that it works okay. I could be wrong, of course.
I haven’t tried it in a while. It feels like I’ve read about a lot of questionable results from doing it that way. I also feel like I’ve read cases where it’s worked in the builder, but not always in the published app. I guess it all depends on how quickly that row is written to the table before a set column action can be performed on top of it.
Another one of those things I wish we had some clarity on how glide handles that behind the scenes.
So there are no user profiles. This is a public facing app accessed through a job ad.
Does that change what we are discussing?
You can still use the method that Jeff described…
As he pointed out, the approach that I described may not be 100% reliable, but his approach is pretty much guaranteed to work. So I’d advise going with that.
Only problem is I am already using the On Submit option to take the user to a Thank You screen after submitting so they don’t think something went wrong and submit again. I had that issue when testing with users.
Jeff’s approach doesn’t require the use of any On Submit action at all. As he said, you can use those template columns as Column Values with the form. They won’t be visible on the screen.
Even if you did need to use an On Submit action, you could create a custom action with multiple steps. But again, that isn’t required in this case.
Template Columns don’t suit as I need to be able to change the values as an application progresses using a Choice button.
I actually stumbled across the answer just now. All you do as add a Screen Column to the form then go to the Data tab and key the default value. When it adds the row it picks up those values in the sheet.
I knew there would be a simple way to do it. It’s such a basic requirement. Perhaps a support note would be good for this so everyone can see it?
I haven’t had any recent problems using a set column action on form submit. It’s was a little flaky several months ago, but Glide’s resolved those issues and it works wonderfully.
I agree. I use it quite a bit now to pass through unique values to both a Table and Sheet at the same time — the issue I have with On Submit actions is that a ROWID can’t get created and set as a column in another sheet/table with one click, but using a separate Unique value that gets temporarily stored in a User Profile field allows me to set it in the form submissions table and an additional sheet/table with a single click.
Sorry for the confusion. You ended up doing it pretty much how I suggested. I was not referring to using template columns in the form response table. What you ended up doing is exactly what I was getting at, but instead of typing values into basic columns in the parent table, I was referring to using template columns instead to hold the values and then pass them through the form as ‘Screen Value’ components to basic columns in the form response table. I tend to still call them ‘Column Values’ instead of ‘Screen Values’, so that may have led to the confusion. Glad you got it working.
Back to the drawing board on this one. It only appeared to be working. Just had 3 new applications arrive. The data I wanted defaulted defaults to the values in the first row … UUUUUGGGGHHH!
BUT, I have a reliable workaround.
As both the fields I want defaulted are subsequently maintained backend via a lookup table Choice I added them as Choice fields to my applicant form. Set visibility as First Name not empty. As this is the first field they enter the choice fields disappear. You have to scroll to see them so gone by the time they get there.
I think Glide need to make default values not seen by user a feature. Very very useful.
…or you could do it it like I suggested with the template columns and pass them through the form as screen values…
I found you cant subsequently change the value of a template column with a choice field as they don’t show in the list of fields available for Choice. Otherwise, yes that works to set values. e.g. set value to 1. New Applicant then in another app I need to be able to change status as they progress.
Problem would be solved if glide added a simple visibility option for fields as visible or non visible rather than needing a condition (although has usefulness as well). Then you just set the default value and voila. Done!
The Screen Value components aren’t visible on the screen and simply pass the template value to any column you choose in the form response table. The templates are only there to pass the value through the form to basic columns. You can change the basic columns all you want after the fact. There is no reason to ever change a template column because it’s only used to pass the value through the form. You wouldn’t use it for any other reason.