Freetutes.com

VB6 beginners tutorial - Learn VB6

Advanced VB6 tutorial - Learn Advanced VB6

VB .NET - Learn Visual Basic .NET

Systems Analysis - System analysis and Design tutorial for Software Engineering


You are here: Visual Basic > Advanced VB6 tutorial > Chapter 13

Giving Your Control a Custom Bitmap

Since your custom control will eventually end up on a developer's toolbox, it needs a bitmap to display in the developer's VB toolbox. You can let the default ActiveX control bitmap show up in the toolbox, or you can set the UserControl's ToolBoxBitMap property to determine the custom control's appearance in a developer's toolbox.

ToolBoxBitMap is like the Icon or Picture property of other controls: You set it by double-clicking the ToolBoxBitMap property or clicking the Add button to the right of the property in the Property Window of the UserControl. Note, though, that unlike the Picture and Icon properties, the ToolBoxBitMap's File dialog box doesn't allow you to choose icon (.ico) files (see Figure 13.4). Instead the ToolBoxBitMap can be a .bmp (bitmap), .gif, .dib, .pal or .jpg file. The image size should be 16´15 pixels, or else it will be scaled by the system with unpredictable (and sometimes unsightly) results.

Choosing a picture file for the UserControl's ToolBoxBitMap. Note that the file types allowed are different from most Picture and Icon properties' file types.
FIGURE 13.4 Choosing a picture file for the UserControl's ToolBoxBitMap. Note that the file types allowed are different from most Picture and Icon properties' file types.


  

<< Previous | Contents | Next >>

Home | About Us | Privacy Policy | Contact Us

Copyright © Freetutes.com | All Rights Reserved