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

RadAutoCompleteBox in RadGrid EditForm trick

1 Answer 74 Views
AutoCompleteBox
This is a migrated thread and some comments may be shown as answers.
Sypher
Top achievements
Rank 1
Sypher asked on 21 Sep 2012, 05:14 PM
I've noticed that the .racInput box in the RACB (InputType=Token) is only 22px wide when it is displayed inside of a RadGrid edit form. This causes the control to seemingly not work when you click on it unless you click on the far left of the empty space. My fix for now is just to call the click on the .racInput whenever the parent .racTokenList is clicked. Here is all I had to add to the page using jQuery:

$(document).on('click', '.racTokenList', function (e) { $(this).find('.racInput').click(); });

Another way of fixing it would probably be to resize the .racInput on display of the .racTokenList... and I'm sure Telerik will eventually fix the issue in the built-in code, but this was a simple fix for me for now. This may also help in other cases where the RACB is not originally displayed on the page.

Attached is what it looks like in our app using the WIndows7 theme. The .racInput is highlighted using the dev tools in Chrome.

1 Answer, 1 is accepted

Sort by
0
Ivana
Telerik team
answered on 26 Sep 2012, 11:45 AM
Hi Bryan,

Thank you for taking the time to inspect the RadAutoCompleteBox more closely.

Yes indeed. Apart from the visualized box which holds the selected entries (tokens in this case), the input in which a user is allowed to type some text is small -- it has a very  small width set to it. This, however, should not cause any problems since when the user clicks on the tokens' holder area the focus goes to the input itself where the user is allowed to type right away.

Would you let me know if this is not how RadAuotCompleteBox behaves at your end?

Regards,
Ivana
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
AutoCompleteBox
Asked by
Sypher
Top achievements
Rank 1
Answers by
Ivana
Telerik team
Share this question
or