ISLabel.Font

Description

The font of the specified label control.

Syntax

object.Font

Part Attribute Type Description
object Required
The object always implements the ISLabel interface

Return Value

StdFont

Example

Display some information about the specified label control, including its font name and font size.

Dim aLabel
Dim aFont
Dim aLabelInfo

Set aLabel = Form.Controls_("Label1")
set aFont = aLabel.Font 

aLabelInfo =_
  "Caption: " & aLabel.Caption & vbNewLine &_ 
  "ShortName: " & aLabel.ShortName & vbNewLine &_
  "TypeName: " & aLabel.TypeName & vbNewLine &_
  "Font Name: " & aFont.Name & vbNewLine &_
  "Font Size: " & aFont.Size               
  
Profile.MsgBox(aLabelInfo) 
Note: This macro should be executed in any event handler of the form control.

In Profile Client v8 on User Interface Font can be found in Maintain > Templates > Health Record Collection Templates > Open the selected form template > Open form editor > Object Inspector > Select the label control in the controls tree > Font.

Version information

Added in v7.8.0