Click here to Skip to main content
15,924,036 members
Home / Discussions / C#
   

C#

 
GeneralRe: Active Tab, change Colour Pin
Mohamad Al Husseiny16-Aug-05 8:55
Mohamad Al Husseiny16-Aug-05 8:55 
GeneralExe file icon Pin
Ming Luo16-Aug-05 2:10
Ming Luo16-Aug-05 2:10 
GeneralRe: Exe file icon Pin
mohammad92916-Aug-05 2:17
mohammad92916-Aug-05 2:17 
GeneralRe: Exe file icon Pin
S. Senthil Kumar16-Aug-05 3:01
S. Senthil Kumar16-Aug-05 3:01 
GeneralRe: Exe file icon Pin
Ami Bar16-Aug-05 18:35
Ami Bar16-Aug-05 18:35 
GeneralAdding ToolTip to ListView Subitem Pin
Member 145978316-Aug-05 0:11
Member 145978316-Aug-05 0:11 
GeneralRe: Adding ToolTip to ListView Subitem Pin
mav.northwind16-Aug-05 0:36
mav.northwind16-Aug-05 0:36 
GeneralRe: Adding ToolTip to ListView Subitem Pin
Alomgir Miah16-Aug-05 3:47
Alomgir Miah16-Aug-05 3:47 
protected int ListViewGetStringWidth(string subItemText)
{
IntPtr hString = Marshal.StringToHGlobalAuto(subItemText);
int width = UnsafeNativeMethods.SendMessage(this.Handle, LVM_GETSTRINGWIDTHW, 0, hString);
Marshal.FreeHGlobal(hString);

return width;
}

protected void SetToolTipText(string toolTipText)
{
if (toolTipText != null)
{
this.toolTip.Active = true;
this.toolTip.SetToolTip(this, toolTipText);
}
}

in the mouse move event handler do the following

curSubItem = item.SubItems[subItemIndex];
if (curSubItem != null)
{
if (curSubItem.Text.Length > 0)
{
subItemTextWidth = this.ListViewGetStringWidth(curSubItem.Text);
if (subItemTextWidth != -1)
{
subItemTextWidth += 6;
if (subItemTextWidth > this.Columns[subItemIndex].Width)
{
this.SetToolTipText(curSubItem.Text);
}
else
{
this.HideToolTip();
}
}
}
}//end curSubItem

Live Life King Size
Alomgir Miah
GeneralRe: Adding ToolTip to ListView Subitem Pin
Member 145978319-Aug-05 23:43
Member 145978319-Aug-05 23:43 
GeneralC# How to run Remote process Pin
mohammad92915-Aug-05 23:50
mohammad92915-Aug-05 23:50 
GeneralRe: C# How to run Remote process Pin
snouto16-Aug-05 8:38
snouto16-Aug-05 8:38 
GeneralRe: C# How to run Remote process Pin
mohammad92916-Aug-05 20:20
mohammad92916-Aug-05 20:20 
GeneralWhats the equivalent of this in C# Pin
Mridang Agarwalla15-Aug-05 23:20
Mridang Agarwalla15-Aug-05 23:20 
GeneralRe: Whats the equivalent of this in C# Pin
J4amieC16-Aug-05 0:06
J4amieC16-Aug-05 0:06 
GeneralRe: Whats the equivalent of this in C# Pin
Dave Doknjas16-Aug-05 13:58
Dave Doknjas16-Aug-05 13:58 
GeneralOutlook Addin Pin
Paul Roullier15-Aug-05 23:14
Paul Roullier15-Aug-05 23:14 
GeneralCode Protection in C# Pin
Anonymous15-Aug-05 22:07
Anonymous15-Aug-05 22:07 
GeneralRe: Code Protection in C# Pin
Guffa16-Aug-05 7:19
Guffa16-Aug-05 7:19 
QuestionCheck if user installed latest Windows Updates? Pin
Bullettooth15-Aug-05 21:58
Bullettooth15-Aug-05 21:58 
AnswerRe: Check if user installed latest Windows Updates? Pin
Dave Kreskowiak16-Aug-05 5:16
mveDave Kreskowiak16-Aug-05 5:16 
Generalserial communications in C# Pin
Atmadarshini15-Aug-05 21:45
Atmadarshini15-Aug-05 21:45 
GeneralRe: serial communications in C# Pin
snouto15-Aug-05 21:59
snouto15-Aug-05 21:59 
GeneralRe: serial communications in C# Pin
Atmadarshini15-Aug-05 22:04
Atmadarshini15-Aug-05 22:04 
GeneralRe: serial communications in C# Pin
sevenacross16-Aug-05 4:12
sevenacross16-Aug-05 4:12 
GeneralRe: serial communications in C# Pin
sevenacross16-Aug-05 4:15
sevenacross16-Aug-05 4:15 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.