Intersoft WebCombo Documentation
WebCombo Advanced Features
See Also Send comments on this topic.
Intersoft WebCombo > WebCombo Advanced Features

Glossary Item Box

WebCombo is an advanced combo box component for ASP.NET web development. To learn the basics and key features of WebCombo, see WebCombo Features Overview.

This topic discusses WebCombo's advanced features in depth, which contains the following topics.

Automatic Data Caching Handler

AllowAutoDataCaching feature is enabled by default. WebCombo implements its own unique data caching mechanism based on the built in ASP.NET caching feature.

The advantage of using WebCombo's data caching mechanism is a more powerful and effective data caching compared to the traditional ASP.NET caching. Consequently, it will significantly reduce server's workloads and dramatically improve server's response time.

The scope of the WebCombo's cache is session. WebCombo will track each session's cache and automatically remove the DataSource object from cache when the time is expired and it is no longer accessed. If the DataSource object is a dynamic object which means that the object is frequently modified, consider to set the AllowAutoDataCaching property to False. However, in most cases, leave this property to True for better performance.



In order to make use of this feature effectively, call the IsDataCached method to check whether the data source is already cached prior to assigning a new data source.

In some scenarios, a different data source can be assigned directly from code by simply assigning the DataSource property to a new data source. In this case, the old cache will be automatically removed and the new instance of cache will be created.

To learn more, see How-to: Disable auto data caching.

ClientAction Engine

ClientAction is a great improvement to the OnTheFly™ Postback architecture. This object is attached per WebCombo instance and designed to bridge the gaps between the client and server. It enables predefined client actions to be executed directly from the server  during OnTheFly Postback (a.k.a. AJAX callback). As the results, it eliminates the needs to write client-side code.

This time-saving feature also allows you to invoke your own client-side function directly from the server code. There are two ways to invoke the predefined client actions. The first is through a static method call, which means that it does not require a WebCombo's instance. For examples, Alert, NavigateTo and so on.

The framework's built-in ClientAction engine enables developers to easily call client-side action or code in the server-side. For examples, GetClientAction().Alert("msg") or GetClientAction().NavigateTo("page2.aspx") can be called directly in the server-side code during page callback.

Scenario 1 - Display message box to user

C# Copy ImageCopy Code
protected void WebCombo1_InitializePostBack(object sender, ISNet.WebUI.WebCombo.PostbackEventArgs e)
{
   // Display alert to user 
   WebCombo1.GetClientAction().Alert("You can't update this row!");
}


Scenario 2 - Refreshing another WebCombo instance

C# Copy ImageCopy Code
protected void WebCombo1_InitializePostBack(object sender, ISNet.WebUI.WebCombo.PostbackEventArgs e)
{
   // Refresh another WebCombo
   WebCombo2.GetClientAction().Refresh();
}                        


Scenario 3 - Navigate to specific page after record addition

C# Copy ImageCopy Code
protected void WebCombo1_InitializePostBack(object sender, ISNet.WebUI.WebCombo.PostbackEventArgs e)
{
   // Called directly in server side codes within OTFPB context.
   WebCombo1.GetClientAction().NavigateTo("StatusForm.aspx?UserId=" +
   e.Row.Cells.GetNamedItem("UserId").Value.ToString());
}

To learn more, see ClientAction Engine How-to topics.

Popup Dropdown List

Since the first version, "floating" result window was one of WebCombo's most powerful features. The result box is using popup window type by default, which can be customized through the ResultBoxWindowType property.


To see the popup window type in action, open a WebCombo sample in the browser and resize your browser's window. Notice that the WebCombo's result box will be displayed on the top of the browser window which is not limited to the browser's size.

Compare the results with the traditional ASP.NET DropDownList control such as shown in the following.

Traditional ASP.NET DropDownList Result Box Window


Notice that the result box of the standard ASP.NET DropDownList is always limited to the size of the browser window. This feature greatly enhances user experiences as the end users can always see the whole data regardless of the browser's size.

Note that this feature is only available in Internet Explorer browsers. Non IE browsers will gracefully fall back to Normal window type.

To learn more, see How-to: Set result box window type.

FAQ

FAQ: How to use WebCombo in dual monitor?

As described in the above topic, WebCombo's result box can be "floating" outside the browser's window. Unfortunately, this feature caused an issue when used in a dual monitor environment, i.e., the result box is not displayed in the secondary monitor. To solve this issue, please set the ResultBoxWindowType property to Normal.

Note that this issue applies only to Internet Explorer browser. The dual monitor issue has been clarified to be a limitation in the Internet Explorer browser.

The following illustration shows how to customize the ResultBoxWindowType property using the WebCombo Designer.

Multiple Columns

You can easily configure WebCombo to display multiple column result window. First, open the WebCombo Designer by right clicking on the WebCombo instance, then choose the WebCombo Designer such as shown in the following illustration.

Designer


Look for the ComboMode property in the LayoutSettings section and make sure that its value is set to MultipleColumn.

MultipleCol1


Now, users can see the results list in the multiple columns mode instead of the single column display in classic ASP.NET DropDown List control.

Multiple

To learn more about multiple columns, see How-to: Use multiple columns mode.

Entry Mode

WebCombo provides 3 types of entry mode such as explained in the following.

To learn more about entry mode, see Entry Mode How-to Topics.

Linked WebCombo

Linking two or more WebCombo is one of the most requested features. While it is feasible to be done in the previous version, it requires extensive code in the client-side. The complexity grows when you need to link a few WebCombo instances together.

Now linking two or more WebCombo is easier than ever. You no longer have to deal with great amount of code, you can simply select the link settings through the server-side properties. The designer enables you to easily select which WebCombo you desire to link.

The Linked WebCombo feature supports the following scenarios:

To learn more, see Linked WebCombo How-to Topics.

Multiple Selection

One of the most powerful features in WebCombo is the Multiple Selection feature. Using the same data binding concept and WebCombo solid architecture, you can easily enable your end users to select multiple items from a list.

WebCombo is designed to support broad and advanced business application scenarios such as Bound mode, Unbound Mode, Unbound ReadOnly mode, AllowBrowseAll mode and many more. The combination of the OnTheFly-PostBack™ and IEMozBridge™ architecture together with the Multiple Selection feature makes data entry and presentation easier and more efficient than ever before. The feature runs consistently in all popular browsers such as Internet Explorer, Firefox, Safari, and Opera.


Multiple Selections


The Multiple Selection feature includes behaviors such as explained in the following:

  1. Data Input

    There are several input modes to accept an item:

    • Using Keyboard

The valid built-in keystrokes are Tab, Enter and the character specified in SeparatorChar property. These keys can be used to accept a selected item only when the ResultBox is shown. This will result in better consistency as a user can hit the Tab key again to move to the next field after the input is done.

    • Using Mouse

When the ResultBox is open, you can select the item by clicking on it, WebCombo will then insert the item and automatically position the cursor ready for next item input.

  1. Navigation

    You can use the left and right arrow keys to navigate from previous item to the next item, or vice versa. WebCombo will automatically determine the entered valid items and set the cursor position accordingly.

  2. Highlight

    You can easily select an item among multiple values by clicking the region of a valid item. When the clicked item is valid (that is, it has a Value), the item will be highlighted similar to the Microsoft Outlook® 2003 TextBox feature. You can delete the selected item by pressing the Delete or Backspace key.

  3. Item Deletion

    Item deletion can be done using the Delete or Backspace key. WebCombo is capable of identifying tokens in the cursor position and delete the previous item when the Backspace key is pressed, it can also delete the next item if the Delete key is pressed. WebCombo can automatically determine the current context when pressing these keys, e.g. whether the user is in editing mode or selection mode. Editing mode is when the ResultBox is shown and the item is not yet valid.

  4. Item Insertion

    WebCombo features an extensive keyboard handling mechanism capable of parsing the tokens intelligently. The MultipleSelection feature can even allow a user to insert an item. This can be done by placing the cursor in the position where you want to insert. Then, start typing and press Tab to select an item, and the new item will be properly inserted among other values.

  5. Advanced features

    WebCombo includes numerous advanced settings related to the MultipleSelection feature. These settings can be found in MultipleSelectionSettings object that contains all information about the MultipleSelection feature. The advanced features are:

    • AllowBrowseAll

    When this property is set to True, you can list all items by pressing Ctrl+Space. Note that when the MultipleSelection property is Enabled and the TextBoxMode property is Editable, the DropDownButton will be disabled and invisible.

    • AllowNotInListText

    This setting allows the user to input text which is not listed in the ResultBox. You should handle the OnValueItemNotInList client-side event to determine how the item should be treated.

    • AutoPositionResultBox

    When this property is set to True, the ResultBox location will be automatically positioned beneath the cursor position.

    • AutoSelectFirstMatch

    When set to True, the first row will always be highlighted. This allows a user to quickly select an item by pressing the Tab key without first having to press the Down arrow key to select.


    Multiple Selections using advanced features

  6. Complete Client-side and Server-side Object Models

    Along with the MultipleSelection feature, numerous client-side methods and properties have been added to both the server-side and client-side objects. Developers are allowed to obtain multiple values on client-side, programmatically add, change or delete any ValueItem, and more.

To learn more about multiple selection, see Multiple Selection How-to Topics.

Load-on-Demand

The load-on-demand feature has been around since early WebCombo version and it was made available to meet the growing complexity of business requirements. One of the requirements is, for instance, controlling data retrieval from a large data source precisely based on the user interaction.

This feature allows developers to write their own code to control the data rows that need to be retrieved from the physical data source through the provided event arguments. This provides an ideal solution for data selection in applications with relatively large data source.

To enable the load-on-demand data retrieval feature, you set the AllowAutoQueryHandler property to False. Consequently, WebCombo will not perform the automatic (default behavior) query handling. You will need to write your own code for your specific data-retrieval scenario in the InitializeDataSource server-side event.

To learn more about Load-on-demand, see How-to: Apply load on demand in WebCombo.

What is OnTheFly-PostBack™

If you are a web developer, you should already be familiar with server postback mechanism where the entire page is submitted back to server for processing and then returned the complete output back to client side. In ASP.NET, a server control requires postback to server in order to process the information and events passed from the client. While ASP.NET has greatly improved the architecture of server-based processing such as server controls and control events, it is still unable to deliver the web experiences expected by both developers and end users since it had to perform standard page postback mechanism which is undoubtedly cause inconvenience and produce slow response between user interactions.

OnTheFly postback is a patented technology by Intersoft Corp eliminating the need to perform full page postback in order to communicate with server resources. This technology is built on the top of ASP.NET® and latest web technology, therefore allowing our commercial server components to better run on .NET-enabled server and to take advantage of the technology in order to produce a better web experience - as stated in Intersoft's vision.

Benefits

There are many benefits when data can be requested and delivered by clients without losing the state of the client. The most significant benefits is improved overall performance and minimized server's workload.

Normally, a standard server control will need to do postback to server in order to interact with server's resources such as retrieving data or do server-specific tasks. Since that the web applications is stateless, there is a need to save latest client state for the whole page when posting back to server. This is done by the VIEWSTATE implementation in Microsoft ASP.NET. There is nothing wrong with the ViewState implementation and in fact it does very well. However, a major performance issue will appear when there are a lot of complex controls in a page, which is caused by large saved view state and the need to send back the whole page's output.

The OnTheFly postback feature allows the implemented controls to interact with server and send back only necessary UI elements, without the need to send the whole page's elements. This dramatically saves the server's resources, time and bandwidth needed to perform server interaction.

The summary of the benefits are:

Rich and smoother user interactions.
Improved performance up to 50%.
Minimized server workload.
Increased end users productivity.
True server-events processing.
Faster rendering and realtime response.
 

About Callbacks

Callbacks is the generic term used by other vendors to identify the postback through XMLHTTP channel over traditional postback. Many developers have asked the difference about the callback with Intersoft's proprietary OnTheFly-Postback™ architecture. So, are there any difference? The answer is yes.

Although more vendors will claim that their products support callbacks, still many of them failed in state persistence as well as tons of issues related to ASP.NET performance and page life cycle. Intersoft's OnTheFly-Postback™ is not a few lines of javascript codes sending request to server through XmlHttp (as of Callbacks), it is a truly integrated client-server architecture with comprehensive server component interfaces for cross-products consistency and reliability resulting in smooth UI interactions.

Following is the details that make Intersoft's OnTheFly-Postback unique and strongly stand out of the crowd:

Conformance to Microsoft .NET's Page framework

There are certainly a few issues that appear with the introduced onthefly-postback feature, such as the state of IsPostBack, the viewstate restoration and so on. Intersoft recognizes that without the compatibility of .NET's page framework, it is unlikely that the architecture will become a solid, mature, and enterprise-ready architecture. Therefore, the architecture has been designed with full support and conformance to the .NET's standard page framework.
The implemented supports are:

About ASP.NET V2.0 Support

At the time of this writing, Microsoft has planned to support what they called "out-of-band callbacks" directly into the ASP.NET V2.0 architecture.

Intersoft's OnTheFly postback architecture has been redesigned and further optimized when built into the WebUI.NET Framework. The architecture has been made "plugable" and thus it could be easily integrated into ASP.NET V2.0's interface once it is available.

However, Intersoft might not be utilizing ASP.NET 2.0's built-in callbacks support due to many of limitation in the .NET Framework itself.

About Mozilla support

Internet Explorer® users have been enjoying the benefits of this architecture since its initial release. Intersoft is proud to announce that the architecture has been redesigned to support Mozilla-based browsers as well. That means, Intersoft has now opened the chance for other platforms such as Macintosh, Linux or Solaris to enjoy the rich features of Intersoft's products, delivering wealth user experience and greater productivity to both developer and end users.

The Mozilla and other Gecko-engine based browsers support is implemented in WebUI.NET Framework V3.0.

See Also