I cloned a BizForm which loads an Online Form.
Is it possible to programmatically set default values to certain fields on a new form ( not an inserted form )? The values must be visible on the form.
I already tried:
viewBiz.FieldControls["FieldName"].Text = "SomeValue";
You dont need to make some customization in file. You can do it in the definition of fields in the Fields tab, when defining the form
There's a attribute Default value
You can use this solution for fixed default values or when using a macro.
It's more difficult when your default value is generated in a method in your custom web part.
For example: when you want to access a default value from an api.
So make an macro, that genrates the value from API. So the only customization will be your custom macro. Assuming this will be supported by Kentico, your modification from the first post not.
Please, sign in to be able to submit a new answer.