Click to return to the Component Development home page    
Web Workshop  |  Component Development

Label Control -- Reference Info


Properties

Caption: Specifies text to be displayed Angle: Specifies angle (counter-clockwise rotation) in degrees Alignment: Specifies how to align text in the control:

0 : Aligned to left (horizontal) and to top (vertical)
1 : Centered (horizontal) and to top (vertical)
2 : Aligned to right(horizontal) and to top (vertical)
3 : Aligned to left (horizontal) and Centered (vertical)
4 : Centered (horizontal) and Centered (vertical)
5 : Aligned to right (horizontal) and Centered (vertical)
6 : Aligned to left (horizontal) and to bottom (vertical)
7 : Centered (horizontal) and to bottom (vertical)
8 : Aligned to right (horizontal) and to bottom (vertical)

BackStyle: Control background:

0 : Transparent
1 : Opaque

FontName: Name of a TrueType font

FontSize: Size of the font

FontItalic: Flag for italics

FontBold: Flag for bold

FontUnderline: Flag for underline

FontStrikeout: Flag for strikeout

Mode: Which mode the text will be rendered in:

0 : Normal (same as the VB Label control)
1 : Normal text with rotation
2 : apply the user specified lines while rendering without rotation
3 : apply the user specified lines while rendering, allow rotation

Param tags such as TopPoints, TopXY, BotPoints, BotXY tags are provided to specify the two lines along which the text will be shown. Visual Basic properties such as TopPoints, TopIndex, TopXY, BotPoints, BotIndex, and BotXY are also supported.


Methods

AboutBox: Displays the About dialog box


Events

Click: When the user clicks the label

Change: When the label caption changes

DblClick: When the user double-clicks the label

MouseDown: When the user presses the mouse button down while the cursor is on the label

MouseMove: When the user moves the mouse when the cursor is on the label

MouseUp: When the user releases the mouse


Sample HTML

   <OBJECT ID=Label1 CLASSID="clsid:99B42120-6EC7-11CF-A6C7-00AA00A47DD2"
         CODEBASE="http://activex.microsoft.com/controls/iexplorer/x86/ielabel.cab#version=4,71,115,0"
         WIDTH=150 HEIGHT=500 VSPACE=0 ALIGN=LEFT>
         <PARAM NAME="Angle" VALUE="270">
         <PARAM NAME="Alignment" VALUE="2">
         <PARAM NAME="BackStyle" VALUE="0">
         <PARAM NAME="Caption" VALUE="Properties">
         <PARAM NAME="FontName" VALUE="Times New Roman">
         <PARAM NAME="FontSize" VALUE="60">
   </OBJECT>

HomeBack to ActiveX Controls Programming Reference



Back to topBack to top

© 1999 Microsoft Corporation. All rights reserved. Terms of use.