Validation of RadWatermarkTextBox - Tooltip DisplayMode doesn't work

0 Answers 56 Views
ToolTip
Valentin
Top achievements
Rank 1
Valentin asked on 28 Mar 2024, 08:18 PM | edited on 28 Mar 2024, 08:58 PM

Hello. Please give an idea to start with ...

I have RadWatermarkTextBox. And I've added INotifyDataErrorInfo to my VM implementation.

When DisplayMode  is Static - I can see validation errors. But When it's Tooltip telerik:ValidationErrorTemplateHelper.DisplayMode="ToolTip"
I can't see. 

By the way. if I use static mode I also don't see red bottom border line. And red arrow at top right corner, my error text is just a black font without read rectangle around and etc.

Looks like missing styles. But I can't understand which one. I imported xaml files for Win11 style. I see that there is a definition for RadWatermarkTextBox Validation Styles.

Valentin
Top achievements
Rank 1
commented on 29 Mar 2024, 07:40 AM

And another question. UpdateSourceTrigger doesn't work as expected when set explicitly to PropertyChanged for RadWatermarkTextBox

I found that some other control has a special attach property like UpdateValueEvent. But this control doesn't have such option.

Dimitar
Telerik team
commented on 29 Mar 2024, 12:14 PM

Hi Valentin, 

I have tested this an d it works on my side. I have attached my test project. Could you please check it and let me know how it differs from your real setup? 

Thank you in advance for your patience and cooperation. 
Valentin
Top achievements
Rank 1
commented on 31 Mar 2024, 09:22 PM | edited

Thank you. Looking at this. 
Dimitar
Telerik team
commented on 01 Apr 2024, 09:33 AM

Hi Valentin, 

Ok, please update the project so it reproduces both issues and send it to me. This way I can proeprly investigate.

I am looking forward to your reply.

Valentin
Top achievements
Rank 1
commented on 01 Apr 2024, 08:08 PM

Hi Dimitar, I found some issues in my code. 
But have another question now. How can I show similar Validation.ErrorTemplate on RadPasswordBox? for example when user forgot to enter password I want to show mark that this is a required field. I already could add binding to my ViewModel via Behaviour.

How can I show Validation error?
Dimitar
Telerik team
commented on 02 Apr 2024, 06:21 AM

Hi Valentin, 

RadPasswordBox inherits RadWatermarkTextBox and this should work the same there. Are there any issues on your side with the password box? 

I am looking forward to your reply.

Valentin
Top achievements
Rank 1
commented on 02 Apr 2024, 06:26 AM

My View model implements INotidyDataErrorInfo. 
To bind value from RadPasswordBox  to ViewModel Property I had to add Behaviour that will be subscribed to passwordChanged event(due to the point that PaassowrdBox.Password is not a Depndency property. 

But in this case it will not show Validation Error as for example RadWatermarkTextBox does. I suppose it works so due to the point that my binding is in Behavior not in PasswordBox itself and probably that's why it doesn't see Validation errors. It's just an assumption from my side.

 

Can you give me an idea how to make it work? Have Validation and binding to VM. I don't care about security reason of storing password in memory in that case. In my application it's not a problem

Dimitar
Telerik team
commented on 03 Apr 2024, 10:44 AM

Hi Valentin, 

This seems a very specific case. Opening a new support ticket and attaching your project there would be better. This way we can properly investigate and determine what is causing this. 

Thank you for your understanding.

No answers yet. Maybe you can help?

Tags
ToolTip
Asked by
Valentin
Top achievements
Rank 1
Share this question
or