473,396 Members | 1,998 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

display "\t" in tooltip in .Net framework

BC
Hi
I am trying to display the formated text, a table like, in the tooptip in C#.
Something like this:
Apple 4
lime 100

I put "\t" after the "Apple".
Somehow the tab "\t" won't show in the tooltip.
When the tooltip shown, it displayed "Apple" only in the tooltip.

But I tried to display the exact text in a MessageBox, it works fine.

Anyone knows how to show the "\t" in the tooptip?

Thanks
BC
Nov 16 '05 #1
3 1799
Jay
try this
toolTip1.SetToolTip(this.btnBind, string.Format("{0} \t {1}", var1,var 2));

Jay

"BC" <bc*****@yahoo.com> wrote in message
news:9b**************************@posting.google.c om...
Hi
I am trying to display the formated text, a table like, in the tooptip in
C#.
Something like this:
Apple 4
lime 100

I put "\t" after the "Apple".
Somehow the tab "\t" won't show in the tooltip.
When the tooltip shown, it displayed "Apple" only in the tooltip.

But I tried to display the exact text in a MessageBox, it works fine.

Anyone knows how to show the "\t" in the tooptip?

Thanks
BC

Nov 16 '05 #2
B C

That was how I coded. I think there is bug in tooltip class in .Net
Framework. The "\r\n" works fine in the tooltip text. But "\t" won't
work. Any text after the "\t" won't be shown in the Tooltip text. But
if I did:

toolTip1.SetToolTip(this.btnBind, string.Format("{0} \t {1}", var1,var
2));
string str = toolTip1.GetToolTip(this.btnBind);

the str had correct text set in the SetToolTip text.

The interesting thing is the same string with "\t" showed in the
MessageBox correctly.

BC

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #3
Hello BC,

Did you have any luck in finding a way to get tabs to work in tooltips?
It would also be nice to add my own formatting like bold and setting
the backcolor to white (not yellow).
pretty limiting the way it is now...

-dave

Nov 16 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: SHYAM SUNDAR E G | last post by:
hi, I want to display tooltip when Hovered on the Combo Box. like, once if we click on the combo, displays all items in the Combo, when i move the mouse on each item, it has to display the tooltip...
5
by: Vinny Vin | last post by:
I would like to display a ToolTip (WinForms) when the Control associated recieves focus (when the control.enter event is triggered) as oppose to having the ToolTip displayed when the mouse hovers...
5
by: Sue | last post by:
Help! I have an asp table with an embedded table. The asp tablerow that contains this table has a static ID assigned of "FilterRow2" (see snippets of code below). When I click on the button to set...
1
by: Nathan Sokalski | last post by:
When testing a form of mine which uses RequiredFieldValidators that have the Display property set to "Dynamic" the ErrorMessage property is automatically removed when an entry is completely typed...
4
by: Jono | last post by:
Hi Everyone, As it says in the title, I'm looking for a way to display a page while long running operations are performed on the server. Ideally, I'd like some way to push the current request...
1
by: Benny Ng | last post by:
Dear All, Now I met one problem in the development of my one application. I have one ASP.NET page. It's for disply the information of customer. But now I have one new requirement. It's to...
0
by: =?Utf-8?B?TWlrZQ==?= | last post by:
Via an ASPX (and code behind) in .net 2.0 I want to be able to "page" though and display the contents of an xml file. So if there are 100 elements, I can display "page 1 of 4" and list 25 elements...
2
by: DKn | last post by:
in C#.Net windows application . how to display a tooltip for a label dynamically. Plz any one help me..
2
by: reetamca | last post by:
Hi All, I need to add the tooltip option to the combo box in html and javascript. When i place the mouse over the options the full text in that option should be displayed. Please help me in...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.