Quantcast
Channel: DevExpress Support Center (Examples)
Viewing all articles
Browse latest Browse all 7205

How to implement the ASPxRibbon as an ASPxGridView customization panel

$
0
0

This example demonstrates how to use an ASPxRibbon in a Web User Control, which can be added to an ASPxGridView's TitleTemplate to represent a control panel for managing common GidView functions.

Due to ASPxGridView specifics, all actions performed with the control require a request to the server in order to take effect. All these requests are performed via callbacks except two operations: switching the control to edit mode and the export operation. These operations are executed via postbacks. For this purpose, we implemented a custom postback event handler.

Another important point is that since the ASPxRibbon is a control intended to be used primarily as a client side static component, it does not keep its state between requests to the server. So, it is necessary to handle saving and restoring of Ribbon items' state on each request. For this purpose, use an ASPxHiddenField.

Please note that in order to enable correct operation of the client side command handler, the following settings need to be adjusted and should not be overridden:

[C#]
ASPxGridView.SettingsBehavior.AllowFocusedRow=true;ASPxGridView.SettingsPager.Visible=false;

[VB.NET]
ASPxGridView.SettingsBehavior.AllowFocusedRow = true ASPxGridView.SettingsPager.Visible = false

Question Comments

Added By: Yorch at: 6/19/2014 4:24:54 PM    

how do you register the RaisePostBackEvent?

Added By: Yorch at: 6/19/2014 4:44:20 PM    

i tried the code on javascript and does not fire the RaisePostBackEvent on the server side.


Viewing all articles
Browse latest Browse all 7205

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>