D
Dilip
I inherited an owner drawn control that subclasses the Windows Forms
ListView control to provide additional functionalities. I wanted to
detect the presence of the Vertical scrollbar so that I can disable a
few buttons. This code didn't work:
foreach (Control c in ownerDrawnListViewObject.Controls)
{
if (c is VScrollBar)
{
return c.Visible;
}
}
This didn't work because, to my surprise,
ownerDrawnListViewObject.Controls.Count returned 0!
Am I going about this the wrong way?
ListView control to provide additional functionalities. I wanted to
detect the presence of the Vertical scrollbar so that I can disable a
few buttons. This code didn't work:
foreach (Control c in ownerDrawnListViewObject.Controls)
{
if (c is VScrollBar)
{
return c.Visible;
}
}
This didn't work because, to my surprise,
ownerDrawnListViewObject.Controls.Count returned 0!
Am I going about this the wrong way?