473,387 Members | 1,834 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,387 software developers and data experts.

displaying many lines in ListView

Hello,
Is there possibility to display many lines of text in a single item (in
ListView)? I'd like the text to wrap. I must use View.Details mode.

If so, how?!
Thx

Piotrek
Nov 16 '05 #1
3 6266

In details mode, it wont be possible to make the text wrap in the .NET
listview. Becoz listview shows only ColumnHeaders to resize. There is no row
headers available. The row height will be automatically determined by the
Fontsize of the control.

You can show the tooltip if the text overflows during mouse hover.

--
Shak
(Houston)
"Piotrek Stachowicz" <dy******@poczta.onet.pl> wrote in message
news:cc**********@news.onet.pl...
Hello,
Is there possibility to display many lines of text in a single item (in ListView)? I'd like the text to wrap. I must use View.Details mode.

If so, how?!
Thx

Piotrek

Nov 16 '05 #2

"Shakir Hussain" <sh**@fakedomain.com> wrote in message
news:#o**************@TK2MSFTNGP09.phx.gbl...
[cut]
You can show the tooltip if the text overflows during mouse hover.


Hi,
Tooltip would be quite a good idea if it weren't for the fact that I 'd
have to associate with ListViewItem, rather than control. Any suggestions
how to do this?

Piotrek
Nov 16 '05 #3
Piotrek,

You have to set the tooltip for control, but the messages will change
dynamically based on users mouse move

The following code demonstrates showing tool tip for first column which
always has text overflown during mousemove of listview.

private void listView1_MouseMove(object sender,
System.Windows.Forms.MouseEventArgs e)
{
ListViewItem item = listView1.GetItemAt(e.X,e.Y);

if(item != null)
{
if(item.Text != "")
{
this.myToolTip.SetToolTip(listView1,item.Text);
}
else
{
this.myToolTip.RemoveAll();
}
}
else
{
this.myToolTip.RemoveAll();
}
}
--
Shak
(Houston)


"Piotrek Stachowicz" <dy******@poczta.onet.pl> wrote in message
news:cc**********@news.onet.pl...

"Shakir Hussain" <sh**@fakedomain.com> wrote in message
news:#o**************@TK2MSFTNGP09.phx.gbl...
[cut]
You can show the tooltip if the text overflows during mouse hover.
Hi,
Tooltip would be quite a good idea if it weren't for the fact that I

'd have to associate with ListViewItem, rather than control. Any suggestions
how to do this?

Piotrek

Nov 16 '05 #4

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

Similar topics

2
by: Aaron Queenan | last post by:
Is there any way to know whether the OnItemCheck is being called in response to a user action (mouse or keyboard) as opposed to the form loading? I have a class which derives from...
1
by: Synthanator | last post by:
Hi, I have found a lot of information about adding items (and sub items) to a listview and that is fine. What I need to be able to do is retrieve the information (items and sub items) back (say in a...
0
by: Jack | last post by:
Hello all, In code, I'm updating the text property of subitems in a Listview which is in Details view. This may be a dumb question, but I can't seem to find a good way to refresh the listview to...
2
by: johnb41 | last post by:
In my app, I need to open up a multipage tiff file, and also display it's thumbnail images IN HIGH QUALITY. (High Quality meaning anti-aliased, and looking good; not rough and pixely) The...
0
by: Eric | last post by:
Visual C++ 2005 Express MVP's and experience programmer's only please!... I need to get the number of lines in a textbox so I can insert them into a listview. The text comes from my database...
0
by: Eric | last post by:
Visual C++ 2005 Express MVP's and experience programmer's only please!... I need to get the number of lines in a textbox so I can insert them into a listview. The text comes from my database...
0
by: Eric | last post by:
Visual C++ 2005 Express MVP's and experience programmer's only please!... I need to get the number of lines in a textbox so I can insert them into a listview. The text comes from my database...
0
by: Eric | last post by:
Visual C++ 2005 Express MVP's and experience programmer's only please!... I need to get the number of lines in a textbox so I can insert them into a listview. The text comes from my database...
1
by: =?Utf-8?B?UmF5IE1pdGNoZWxs?= | last post by:
Short of writing a custom version of the ListView control, is there a way to force the column headers to contain multiple lines. The problem is that the actual values of the items in each column...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
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...

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.