This is a migrated thread and some comments may be shown as answers.

Default values and RadListViewInsertedEventArgs.KeepInInsertMode

3 Answers 45 Views
ListView
This is a migrated thread and some comments may be shown as answers.
Alain
Top achievements
Rank 1
Alain asked on 27 Mar 2012, 12:34 PM
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

3 Answers, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 30 Mar 2012, 10:22 AM
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.
0
Alain
Top achievements
Rank 1
answered on 30 Mar 2012, 01:16 PM
Hi Maria,

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

Best regards,
Alain

0
Maria Ilieva
Telerik team
answered on 04 Apr 2012, 11:19 AM
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.
Tags
ListView
Asked by
Alain
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Alain
Top achievements
Rank 1
Share this question
or