Default values and RadListViewInsertedEventArgs.KeepInInsertMode

4 posts, 0 answers
  1. Alain
    Alain avatar
    33 posts
    Member since:
    Feb 2009

    Posted 27 Mar 2012 Link to this post

    Hello

    System: ASP.NET AJAX v2012.1.215.40
    Visual Studio 2010

    We use ShowInsertItem(DefaultValues) to display the <InsertItemTemplate> and give the possibility to insert new data with default values.
    After inserted data from the <InsertItemTemplate>, we keep this template open by putting the option RadListViewInsertedEventArgs.KeepInInsertMode of the RadListView ItemInserted event to true.

    Everything works fine, except that we want to continue to display the default values in the newly <InsertItemTemplate>,.(after the posback), Currently, the default values are not displayed anymore.

    Is there an option to keep these default values in this case?

    Best regards,
    Alain
  2. Maria Ilieva
    Admin
    Maria Ilieva avatar
    4017 posts

    Posted 30 Mar 2012 Link to this post

    Hello Alan,

    I suppose the presented issue is related to the fact that after the insert you are keeping the form opened and in this case the InsertCommand does not fires correctly. I would suggest you to try manually fire InitInsert command on prerender by using a flag to check if insert has been performed.

    Give this a try and let me know if this makes any difference.

    All the best,
    Maria Ilieva
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Alain
    Alain avatar
    33 posts
    Member since:
    Feb 2009

    Posted 30 Mar 2012 Link to this post

    Hi Maria,

    Could you give an code example how to fire the InitInsert command correctly?
    Thank you,.

    Best regards,
    Alain

  5. Maria Ilieva
    Admin
    Maria Ilieva avatar
    4017 posts

    Posted 04 Apr 2012 Link to this post

    Hello,

    You could call the:
    RadGrid1.MasterTableView.IsItemInserted = true;

    based on the set flag.

    Greetings,
    Maria Ilieva
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top