Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 312789
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T08:02:54+00:00 2026-05-12T08:02:54+00:00

<TextBox Name=txtInput> <TextBox.ToolTip> <ToolTip Name=TestToolTip> This a test message </ToolTip> </TextBox.ToolTip> private void btnClick_Click_1(object

  • 0
<TextBox Name="txtInput">
<TextBox.ToolTip>
    <ToolTip Name="TestToolTip">
        This a test message
    </ToolTip>
</TextBox.ToolTip>

private void btnClick_Click_1(object sender, RoutedEventArgs e)
{
    txtInput.Focus();
    ToolTipTest.IsVisible = true;
}

When the button is clicked the tooltip is shown on the button, I want to simulate putting mouse pointer on the textbox, the toolbox to be shown for the textbox

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T08:02:54+00:00Added an answer on May 12, 2026 at 8:02 am

    First of all, you should be using the standard validation for something like what you are doing. From your comment above I can tell that’s what you are doing and you should know that WPF has a really good builtin system for doing exactly what you want without doing it so imperatively (and very reusable).

    Here’s an example of a style you can apply to, say, all textboxes when the value the are bound to doesn’t validate (using IDataErrorInfo).

    <Style.Triggers>
        <Trigger Property="Validation.HasError" Value="true">
            <Setter Property="ToolTip">
               <Setter.Value>
                    <ToolTip Content="{Binding RelativeSource={RelativeSource Self}, 
                       Path=(Validation.Errors)[0].ErrorContent}" IsOpen="true" />
               </Setter.Value>
            </Setter>
        </Trigger>
    </Style.Triggers>
    

    You might also consider a more standard UI that utilizes the adorner layer to put a validation failure indicator next to the control that failed validation. Here’s a sample on that:

    http://blogsprajeesh.blogspot.com/2009/03/handling-error-in-wpf-idataerrorinfo.html

    Good luck.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 195k
  • Answers 195k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Bypass away. ValidateRequest is just a weak attempt to prevent… May 12, 2026 at 7:02 pm
  • Editorial Team
    Editorial Team added an answer &nbsp; is an HTML-specific encoding. You were right first time… May 12, 2026 at 7:02 pm
  • Editorial Team
    Editorial Team added an answer System.Text.StringBuilder sb = new System.Text.StringBuilder(); using (System.IO.StringWriter sw = new… May 12, 2026 at 7:02 pm

Related Questions

<asp:TextBox ID=tbName CssClass=formField MaxLength=<%=Constants.MaxCharacterLengthOfGameName %> runat=server></asp:TextBox> The code above does not work. I can
Given a StackPanel: <StackPanel> <TextBox Height=30>Apple</TextBox> <TextBox Height=80>Banana</TextBox> <TextBox Height=120>Cherry</TextBox> </StackPanel> What's the best
Name: <%= Html.TextBox(txtName, 20, new { @class = hello }) %> I want that
I have a multiline textbox : <asp:TextBox ID=txtBody runat=server TextMode=MultiLine Rows=10 Width=95% /> In

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.