Skip to content

DevExpress-Examples/asp-net-web-forms-grid-delete-confirm-dialog-with-dont-ask-me-again-option

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Grid View for ASP.NET Web Forms - How to implement a delete confirmation dialog with a "don't ask me again" option

This example demonstrates how to implement a delete confirmation dialog with an option to prevent its display for subsequent grid row deletions.

Delete Confirmation Dialog

Implementation Details

The confirm dialog is based on the ASPxPopupControl. The popup contains the dialog content wrapped in a WebUserControl.

Note: In this example, the "Don't ask for confirmation" check box's value is stored in a client JavaScript variable (dontAskConfirmation). We recommend that in a real-life application, you save this value to a user-specific storage such as cookies or user profile settings.

The example application uses the following techniques:

  • The ID field value of the processed row is stored in the client rowVisibleIndex variable.

  • The ASPxPopupControl is made transparent so that it displays its child ASPxRoundPanel as the dialog's immediate container.

  • The ASPxPopupControl is used in modal mode and configured to always be displayed at the Grid View's center.

  • The "Yes" button is the dialog's default button (its ID is assigned to the ASPxRoundPanel's DefaultButton property), so users can press Enter to submit the dialog. The "Yes" button programmatically receives the input focus after the dialog is shown.

Files to Review

Documentation

More Examples

About

Use the ASPxPopupControl to implement a delete confirmation dialog with a "don't ask me again" option.

Topics

Resources

License

Stars

Watchers

Forks

Contributors 4

  •  
  •  
  •  
  •