Unicode Controls & Classes for VB6 - Version 4

clsCommDialogs.ShowFont Function

Creates a Font dialog box that enables the user to choose attributes for a logical font. These attributes include a font family and associated font style, a point size, effects (underline, strikeout, and text color), and a script (or character set).
Each parameter of this function is in [IN/OUT]

Syntax
Public Function ShowFont (ByRef sFontName As String, _
ByRef lFontColor As Long, _
ByRef bFontBold As Boolean, _
ByRef bFontItalic As Boolean, _
ByRef bFontUnderline As Boolean, _
ByRef bFontStrikeout As Boolean, _
ByRef iSize As Integer) As Boolean
Parameters
Parameter Description
ByRef sFontName As String The font name
ByRef lFontColor As Long The font color
ByRef bFontBold As Boolean Is the font bold?
ByRef bFontItalic As Boolean Is the font italic?
ByRef bFontUnderline As Boolean Is the font underline?
ByRef bFontStrikeout As Boolean Is the font strikeout?
ByRef iSize As Integer The font size (in points)
Remarks
Returns True if the user selected a new font then confirmed

This code will show the font dialog for the current form and show you the chosen font size
Option Explicit

Private Sub Form_Load()

Dim ocd As New clsCommDialogs
Dim iSize As Integer 'I want it IN/OUT
iSize = 10
ocd.ShowFont "Verdana", vbRed, True, False, False, False, iSize

MsgBox "The new font size is " & iSize

End Sub