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

Add item manually via button

2 Answers 52 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Brock
Top achievements
Rank 1
Brock asked on 31 Dec 2012, 05:00 PM
Hello, I'm using the following example in the demos (Specifically the server side automatic one using VB code):

http://demos.telerik.com/aspnet-ajax/combobox/examples/populatingwithdata/autocompletesql/defaultcs.aspx

I would like to be able to display/enable a button that is triggered when no match is found for what you have entered, that button would allow you to insert a new row into my table of items bound to the combobox using the text currently typed in the entry section of the combobox.

Are there any examples you can provide of how to do this?


2 Answers, 1 is accepted

Sort by
0
Nencho
Telerik team
answered on 03 Jan 2013, 03:08 PM
Hello Brock,

I can suggest you to use the ClientItemsRequested event handler, in order to determine if there is a match with the currently typed text and enable/disable the button. In addition, you could perform the insert operation in the OnClick event handler of the button. I have prepared a sample project for you demonstrating the suggested implementation. Please find the sample attached.


Kind regards,
Nencho
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
Brock
Top achievements
Rank 1
answered on 07 Jan 2013, 04:42 PM
This is perfect. Thank you!
Tags
ComboBox
Asked by
Brock
Top achievements
Rank 1
Answers by
Nencho
Telerik team
Brock
Top achievements
Rank 1
Share this question
or