The list of form controls available in the Essential Studio are as follows:
The form control value can be obtained on the post back in the following ways.
The following sections explain how to get the values on the post back in these controls. You can create the EJ form controls, and define the form method as post and also define the respective action for the form post back. This is demonstrated in the following code example.
Figure 1: Post back value using Request object
Figure 2: Post back value using the FormCollection object
Figure 3: Post back value using Parameters
Strongly-Typed HTML Helper: The control supports strongly typed HTML helpers represented by lambda expressions that have model or template passed into the View. The Extension method is used to get a value from the model. The EditorFor takes lambda as a parameter that tells the helper with element of the model to use in the typed view. This enables the better compile-time checking of the views that allow you to find errors at build-time instead of at runtime, and also enables better code intelligence support within the view templates. The following steps explain how to get the values by using the Scaffolding methods.
1. Create the model for your requirement.
2. Create an action method that renders UI on the view page, and passes an empty model to be bound to the view page.
3. Create a strong typed view based on your model.
4. Create an action method, FormPost that handles the Post request and processes the data. In the action method, you can pass a model as the parameter. That model has UI input field data.
Figure 4: Selected values in the post action
|Article ID:||Published Date:||Last Revised Date:||Platform:||Control:|
or the page will be automatically redirected to sign-in page in 10 seconds.