User Interface

Labels
AJAX(112) App Studio(8) Apple(1) Application Builder(245) Application Factory(207) ASP.NET(95) ASP.NET 3.5(45) ASP.NET Code Generator(72) ASP.NET Membership(28) Azure(18) Barcode(2) Barcodes(3) BLOB(18) Business Rules(1) Business Rules/Logic(140) BYOD(13) Caching(2) Calendar(5) Charts(29) Cloud(14) Cloud On Time(2) Cloud On Time for Windows 7(2) Code Generator(54) Collaboration(11) command line(1) Conflict Detection(1) Content Management System(12) COT Tools for Excel(26) CRUD(1) Custom Actions(1) Data Aquarium Framework(122) Data Sheet(9) Data Sources(22) Database Lookups(50) Deployment(22) Designer(177) Device(1) DotNetNuke(12) EASE(20) Email(6) Features(101) Firebird(1) Form Builder(14) Globalization and Localization(6) How To(1) Hypermedia(2) Inline Editing(1) Installation(5) JavaScript(20) Kiosk(1) Low Code(3) Mac(1) Many-To-Many(4) Maps(6) Master/Detail(36) Microservices(4) Mobile(63) Mode Builder(3) Model Builder(3) MySQL(10) Native Apps(5) News(18) OAuth(9) OAuth Scopes(1) OAuth2(13) Offline(20) Offline Apps(4) Offline Sync(5) Oracle(11) PKCE(2) Postgre SQL(1) PostgreSQL(2) PWA(2) QR codes(2) Rapid Application Development(5) Reading Pane(2) Release Notes(184) Reports(48) REST(29) RESTful(29) RESTful Workshop(15) RFID tags(1) SaaS(7) Security(81) SharePoint(12) SPA(6) SQL Anywhere(3) SQL Server(26) SSO(1) Stored Procedure(4) Teamwork(15) Tips and Tricks(87) Tools for Excel(2) Touch UI(93) Transactions(5) Tutorials(183) Universal Windows Platform(3) User Interface(338) Video Tutorial(37) Web 2.0(100) Web App Generator(101) Web Application Generator(607) Web Form Builder(40) Web.Config(9) Workflow(28)
Archive
Blog
User Interface
Tuesday, May 22, 2012PrintSubscribe
Modifying User Interface with CSS

Code On Time web applications use Cascading Style Sheets (CSS) to theme the application elements, including colors, fonts, backgrounds, borders, paddings, margins, and other embellishments.

The screen below shows the Employees page of a web application generated using Social theme.

Employees page of a Code On Time web application using Social theme.

Most modern browsers have built-in page inspection capabilities. For example, if you are using Internet Explorer 9, you will need to press F12 to bring up Developer Tools. On the menu, click on Disable / CSS menu option.

Disable CSS using the Developer Tools in Internet Explorer 9.

The page style sheet will be disabled, and the page will look like the screenshot below. You can see that it is now “black on white” - just black text and blue links. If you want to completely revamp the page, it may be best to start from here.

Employees page of a Code On Time web application with CSS disabled.

Alternatively, you can add incremental enhancements to existing themes. Let’s make a cosmetic enhancement to the Social theme.

On the Developer Tools menu bar, click on Disable / CSS menu option again to enable the site styling. Click on the Arrow icon on the toolbar to activate Inspection mode. In this mode, when you mouse over an element in the page, it will be surrounded by a blue border.

Developer Tools Inspection mode will overlay a blue background on moused over page elements.

Click on the first cell underneath the Address column. The Developer Tools window will find the HTML corresponding to the selected element. Three CSS classes Cell, Address, and StringType are currently assigned to the table cell. Let’s create a CSS class that will add a gray background to the Address column.

Select the first cell underneath the Address column on the Employees page of the Code On Time web application.

Start Code On Time web application generator, click on the project name, and press Develop to open the project in Visual Studio. In the Solution Explorer, right-click on the ~/App_Themes/MyCompany folder and click on Add New Item option. If you changed the namespace of your application, then choose the corresponding folder.

In the Solution Explorer, right-click on the ~/App_Themes/MyCompany folder and click on Add New Item option.

In the window that opens, select your programming language, and then choose Style Sheet. Optionally rename the file, and then press Add.

Select 'Style Sheet' option, and press Add.

Replace the default text in the style sheet with the following rule.

.Cell.Address
{
    background-color:#F2F2F2!important;
    border-bottom-color:#F2F2F2!important;
}

Note the use of the !important suffix. This suffix needs to be used when your custom CSS rules come into conflict with the core theme, and you would like your own rule to prevail.

Save the file, and refresh the web page. You will see that the Address column now has a gray background.

The Address column of the Employees grid view is now stylized with a gray background.

Cascading style sheets offer an infinite number of options to affect the presentation of pages without changing a single line in the web application itself. Applications created with Code On Time do not explicitly specify colors or fonts anywhere in the source code. You can alter your application to your exact specifications.

Friday, May 11, 2012PrintSubscribe
Grouping Data Views Under the Same Tab

It is possible to create multi-level master-detail pages in a Code On Time web application. One option is to render the master-detail data views in a flat list one under another. Another option is to group the detail data views in the same container.

In a Northwind sample with a Classic page layout, the Customers page will have the Customers master data view at the top, and three child data views in their own tabs underneath.

 Customers page layout of data views in two containers.

The child data views belong to the same container, and have tabs as activators.

Northwind web application using Classic page layout.Northwind web application using Classic page layout.

In the above layout, the Order Details tab is a child of the Customers data view. Let’s make the Order Details data view a child of Orders data view and have it displayed when Orders tab is selected.

Start the Project Designer. Double-click on Customers / container2 / view4 data view node.

Child data view selected in Code On Time Project Explorer.

Change the following properties:

Property New Value
Text Orders
Filter Source view2
Filter Field #1 OrderID
Auto Hide Self

Press OK to save the data view. On the tool bar, press Browse to generate the application.

When your default web browser opens, navigate to Customers page. You are presented with a list of Customers. Select a customer, and the Orders and Customer Demo tabs of container2 will become visible. Select an Order, and relevant Order Details will appear underneath.

Northwind web application with three-level master/detail layout arranged using tabs.Northwind web application with three-level master/detail layout arranged using tabs.

If you choose Customer Demo tab, then both Orders and Order Details data views will become hidden.

When switched to the Customer Demo tab, Orders and Order Details data views are hidden.

Tuesday, May 8, 2012PrintSubscribe
Feature: Adaptive Filtering

Code On Time web applications offer adaptive filtering out of the box. Adaptive filters limit the list of filtering options according to the current data set and other active filtering options.

For example, consider the Northwind sample web application. Navigate to the Products page. Mouse over the Category Name column header, and activate the dropdown. Click on “Beverages” filter option.

Select the 'Beverages' filtering option from the Category Name column header.

You will see the list of products has been filtered to only display those records with a Category Name of “Beverages”.

Now, filter Supplier Company Name by “Exotic Liquids” using the same method. The combination of filters has produced two matching records.

Filters applied on 'Category Name' and 'Supplier Company Name' fields in a list of products.

Activate the dropdown for Category Name again. You will see that the list of categories has been reduced to only those that match the other filtering constraints (Supplier Company Name equals Exotic Liquids).

Category Name filtering options have been adaptively filtered to only show options relevant to the current data set.

Clear the Category filter by clicking on the text “Category Name equals Beverages”.

Clear a filter by clicking on the filter description.

Filters do not require lookup tables. The filter options are drawn from the data set itself. For example, activate the drop down for Reorder Level in the list of Products. If Supplier Company Name is filtered to “Exotic Liquids”, you can see that the only available filtering options are “10” and “25”, which match the current data set (shown above).

Reorder Level filtering options have been reduced due to adaptive filtering.

You can clear the whole filter by pressing the “x” on the right side of the filter header.

Clear the entire filter by clicking on the 'x' icon at the very right of the filter detail bar.

Filters will continue to adapt regardless of the complexity of a filtering operation. For example, activate the dropdown for Category Name, and click on “Filter…” option.

Filter option on the dropdown of 'Category Name' header.

Toggle the checkboxes next to the following categories: “Beverages”, “Dairy Products”, “Meat/Poultry”. Press OK to apply the filter.

Category Name multi filter selection with several options checked.

Click on text Unit Price in its header to sort the products in descending order of price.

List of products sorted in descending order of Unit Price.

Activate the Unit Price dropdown, and click on Number Filters | Between. Write “10” and “30” in each box, respectively.

Filter 'Unit Price' to all records between '10' and '30'.

Press OK to apply the filter.

Activate the Supplier Company Name dropdown, and click on “Filter…” option. Checkmark several suppliers from the list, and press OK to apply the filter.

Include several filtering parameters for 'Supplier Company Name' field

Activate the dropdown for Reorder Level and click on “Filter…” option. Choose several reorder levels and press OK to apply the filter.

Include several filtering parameters for 'Reorder Level' field

The filtering options will all be displayed in a filter detail bar underneath the action bar. You may have noticed that as you made each filter, the subsequent filters had less values. This is due to the power of adaptive filtering.

You can also click on the text of any specific filter description to remove that filter.

Clear a filter from the list of products by clicking on the specific filter description.