Pages / Data Views

  Search by First Letter

Table of Contents
Pages / Data ViewsPrint||
Search by First Letter

You would be lost while browsing the old fashion phone book or scrolling through the entries of your modern-day contact list on a smart phone without the alphabetical index of entries. A menu of first letters rendered on data pages provides similar productivity enhancement.

This screen shot shows the Search by First Letter enabled in a data view in a Code On Time web application.

Data view with enabled 'Search by First Letter' feature in a Code On Time web application

If you want to enable Search by First Letter, then select the project name on the start page of the web application generator and click Design. Expand a page node in Project Explorer and select the data view that will have the alphabetize search enabled. Toggle the “Search by First Letter” option and re-generate your application.

Property 'Search by First Letter' enabled in a data view

The “first letter” is a bit of a misnomer. The application will find distinct first characters in the first visible data field of type String. If more than one distinct character is detected then the sorted menu of characters is rendered above the “grid” views of the data controller linked to the data view.

'Search by First Letter' is represented by a menu of first characters in the first searchable string data field of a data view.

If a user clicks on a symbol then the data is automatically filtered according to the selection. The following screen shot show what happens if a user clicks on the latter “A” above the list of products in the Northwind sample. This selection activated “begins with…” filtering option on the first column of the gird view.

'Product Name begins with A' is the result of clicking on the first letter.

Users can accomplish the same end result by a selecting the filtering option from the context menu of the first column.

The alternative method of activating the 'Begins With...' filter

Search by First Letter is sensitive to the current set of user-defined filters. The following screen shot shows exactly the same list of products that belong to “Beverages” and “Seafood” categories. The number of symbols in the Search by First Letter menu is less than the number of symbols available when all categories allowed in the view. All filtering options in Code On Time web applications are adaptive.

Adpative nature of 'Search By First Letter'

Search by First Letter is also displayed on a data view that is configured to have “Search on Start”. This option can be enabled in the data view properties. You will find the check box below the “Search by First Letter” option.

Enabling data view properties 'Search by First Letter' and 'Search on Start' will result in the following presentation when users arrive to the Products page.

Users can remove the filter by clicking on the close button on the right-hand side of the filter description.

Alternatively, users can “mouse” over the filter element in the filter description area and have the filter removed with a single mouse click without affecting any other active filters.

Mouse click on the filter element in the filter details will remove the filter without affecting any other active filters