Visual Basic Reference
See Also Example Applies To
Returns or sets a reference to a picture to display in a control when it is disabled. (That is, when its Enabled property is set to False.)
object.DisabledPicture [= picture]
The DisabledPicture property syntax has these parts:
|object||An object expression that evaluates to an object in the Applies To list.|
|picture||A Picture object containing a graphic, as described in Settings.|
The settings for picture are:
|(None)||(Default) No picture.|
|(Bitmap, icon, metafile)||Specifies a graphic. You can load the graphic from the Properties window at design time. At run time, you can also set this property by using the LoadPicture function on a bitmap, icon, or metafile, or by setting it to the Picture property of another control.|
The DisabledPicture property specifies a picture object to display when the control (such as a CommandButton) is disabled. The DisabledPicture property is ignored unless the Style property of the control is set to 1 (graphical).
The picture is centered horizontally and vertically on the control. If there is a caption as well as a picture, the picture is centered above the caption. If the picture object is too large to fit on the control, then it is clipped.
If no picture is assigned to the DisabledPicture property, but one is assigned to the Picture property, then a grayed version of that picture is displayed when the control is disabled.