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

Automatically displaying validation tooltip in RadComboBox

2 Answers 156 Views
ComboBox
This is a migrated thread and some comments may be shown as answers.
Big
Top achievements
Rank 1
Big asked on 05 Sep 2011, 01:28 PM
Hi,

I need to make an editable Telerik RadComboBox show a customized tooltip when the data entered is invalid (in Silverlight). More specifically, instead of the error message I want to display an "X" in a red circle, and I want it to happen automatically (i.e., the user shouldn't have to mouse over the upper-right corner).

I've done the customizations. My problem is that the tooltip won't display the first time there is a validation error, but it will display for all subsequent errors. I need it to happen the first time too.

Here is the project containing the customizations I've done using Expression Blend. Just enter a non-numeric string in the radcombobox to make it invalid. Then make it valid and invalid once more, and you'll see the tooltip. The style I created is in App.xaml.

http://www.megaupload.com/?d=41ER0ER2

Thanks in advance.

EDIT: for quicker reference, here is the code for App.xaml:
http://pastebin.com/fExRcTKi

Also, it would be great if it were possible to keep the tooltip visible for as long as the data is invalid (in other words, once the user moves the mouse pointer away from the upper-right corner, the tooltip should not vanish).

2 Answers, 1 is accepted

Sort by
0
Pana
Telerik team
answered on 08 Sep 2011, 08:52 AM
Hi Big,

The first link display an error: "The file you are trying to access is temporarily unavailable. Please try again later."

Hopefuly the App xaml works.

I have removed the ValidationTooltip presenter from the RadComboBox. And added a small red x visual on the proper place. There are Visual States that could be used to show and hide that mark later. For more information please check the attached project.

Regards,
Pana
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

0
Big
Top achievements
Rank 1
answered on 09 Sep 2011, 02:12 PM
Hi Pana,

Thank you, that's exactly what I needed.
Tags
ComboBox
Asked by
Big
Top achievements
Rank 1
Answers by
Pana
Telerik team
Big
Top achievements
Rank 1
Share this question
or