Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview

On this lesson, we will analyze the “Grid Dropdown List” control that allow us to include a dropdown list of values on each row under any grid table that we have in our application. Like we observed in other grid-controls, it’s mandatory to have a dataset created before we start with the creation process.

How to create a “Grid Dropdown List” control?

Turn to the page where we are going to include this object. Under the “Controls” section, choose the “Grid Dropdown List” option. Click on “New” button

...

Turn to “Data Binding” tab and connect to the dataset that we created in the previous lesson as “DS_UsersHW_Get” in database. This reference to the dataset will show the column on the same grid than the other columns in the page.

...

Info

Keep in mind that the dropdowns need to be connected to stored procedures that retrieve 2 parameters: first one intended to be the value and the second one as description that we will display inside the dropdown. Syntax on “Options” text box should have the following format like in the example “1,2018;2,2019;3,2020;4,2021;5,2022” with comma to separate the key-value and semicolon to separate the pairs.

Click on “Submit” button

...

Let’s click on “Preview” button to verify that the new column is added on the grid

...

Recap

On this lesson, we learnt how to include a dropdown field inside the grid table adding a new column. Certain information is limited to the options that we can offer in this dropdown. Like in the other grid-controls, we can store the information after triggering a save button in the database.