J
Joep
L.S.,
I am using the picture box's paint event to load an image if not yet loaded.
The picture box is one of many that together occupy the area of a panel. Not
all boxes are visible so not all images have to be preloaded.
Problem is that some images do show while others do not.
My paint handler just loads the image of not yet loaded.
Do I have to call the original paint handler to do the painting? I am not
painting anything from my paint handler but some images do get painted.
A little confused...any one has a clue?
This is in the handler:
PictureBox p = (PictureBox) sender;
if( p.Tag is string )
{
if( p.Image == null )
{
p.SuspendLayout();
p.Image = Image.FromFile( m_imageFile );
p.ResumeLayout();
}
}
T.I.A.
I am using the picture box's paint event to load an image if not yet loaded.
The picture box is one of many that together occupy the area of a panel. Not
all boxes are visible so not all images have to be preloaded.
Problem is that some images do show while others do not.
My paint handler just loads the image of not yet loaded.
Do I have to call the original paint handler to do the painting? I am not
painting anything from my paint handler but some images do get painted.
A little confused...any one has a clue?
This is in the handler:
PictureBox p = (PictureBox) sender;
if( p.Tag is string )
{
if( p.Image == null )
{
p.SuspendLayout();
p.Image = Image.FromFile( m_imageFile );
p.ResumeLayout();
}
}
T.I.A.