Ticket Q264164
Visible to All Users
Duplicate

How to disable an automatic saving when changing the row in an editable list view

created 15 years ago

How can I disable the automatic saving when changing the row in an editable list view?
We want to allow the capture of multiple records in the grid and only save when the user decides to press the Save button. Currently, moving from edited row prompts confirmation message “Do you want to save changes?” which is not suitable for our application.
Thanks!

Answers

created 15 years ago

Hello,
Thanks for contacting us.
To solve your problem, do the following:

  1. Create a ViewController and override its OnActivated method;
  2. In the overridden OnActivated method, use the Frame.GetController method to access the WinDetailViewController instance;
  3. Set the SuppressConfirmation property of the WinDetailViewController instance to True;
    See Also:
    http://documentation.devexpress.com/#Xaf/DevExpressExpressAppWinSystemModuleWinDetailViewController_SuppressConfirmationtopic
    http://documentation.devexpress.com/#Xaf/DevExpressExpressAppWinSystemModuleWinDetailViewController_AutoCommitListViewtopic
    AutoCommitListView - disable save dialog on list view
    how to disable autosave confirm?
    Thanks,
    Dennis
    Show previous comments (1)
    Dennis Garavsky (DevExpress) 15 years ago

      Hello,
      Thanks for the feedback.
      Meantime, you can use the controller from the SystemModules - Make it possible to edit multiple records in an editable ListView at once and save the changes only when needed suggestion. I haven't tested it with all the scenarios supported by XAF, but possibly it will help you. Please let me know how this works for you.
      Thanks,
      Dennis

      O O
      Olivier Jacot-Descombes 9 years ago

        I am not finding any WinDetailViewController. Is this information outdated or am I looking at the wrong place?

        Dennis Garavsky (DevExpress) 9 years ago

          @Olivier Jacot-Descombes:
          Yes, this thread describes the outdated API, which is not longer available in the latest product version. For that purpose, the thread is duplicated to the SystemModules.Win - Make it possible to edit multiple records in an editable ListView at once and save the changes only when needed thread, which describes a more recent solution using the ModificationsController class. To learn more on built-in XAF controllers and ways to customize them, please visit the following help articles:
              Concepts > Extend Functionality > Built-in Controllers and Actions
              Concepts > Extend Functionality > Customize Controllers and Actions
          I hope you find this information helpful.

          Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

          Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.