Spread Windows Forms 7.0 Product Documentation
Picture Property
See Also  Example Support Options
FarPoint.Win Assembly > FarPoint.Win Namespace > FpCheckBox Class : Picture Property


Glossary Item Box

Gets or sets the array of pictures to use as the check box image.

Syntax

Visual Basic (Declaration) 
Public Overridable Property Picture As CheckBoxPicture
Visual Basic (Usage)Copy Code
Dim instance As FpCheckBox
Dim value As CheckBoxPicture
 
instance.Picture = value
 
value = instance.Picture
C# 
public virtual CheckBoxPicture Picture {get; set;}

Property Value

CheckBoxPicture object containing the picture

Remarks

If you prefer, you can use your own custom pictures for any or all of the pictures that represent the check box states. Provide the picture as a CheckBoxPicture object. The CheckBoxPicture object lets you specify different pictures for the different check box states.

Check boxes can also display background pictures. Set the BackgroundImage property to specify the background picture.

Specify the alignment for the check box picture and text using the PictureAlignH and PictureAlignV properties.

Specify how the text and the check box picture are aligned using the TextAlign property.

Set the ThreeState property to specify whether the check box has two or three states.

This property is available at run time only.

Tip: When using custom pictures to represent states, try to create a consistent look and feel for the check box cell. Also, be aware of common interface conventions used to represent states, such as using lighter shades of text or graphics to represent the grayed (indeterminate) state.

Example

C#Copy Code
control.ThreeState = true;
control.Checked = false;
control.Picture[1] = Image.FromFile("..\\check1.bmp");
Visual BasicCopy Code
control.ThreeState = True
control.Checked = False 
control.Picture(1) = Image.FromFile("..\check1.bmp")

Requirements

Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8

See Also

© 2002-2014 ComponentOne, a division of GrapeCity. All Rights Reserved.