To check the Text Width, how to set the scale mode?
Is it -
Debug.Print .ScaleMode = 1
Or
Me.ScaleMode = 1
Which one does it work?
I test it with below code
Private Sub Command1_Click()
Dim xStr As String
xStr = "W"
With frmLabel
.Font.Name = "Arial"
.Font.Size = 10
'Debug.Print .ScaleMode = 1
'0 to 7
Me.ScaleMode = 7
Debug.Print .TextWidth(xStr) ' TextWidth = 435
.Font.Size = 14
Debug.Print .TextWidth(xStr) ' TextWidth = 645
End With
End Sub
How could I define the kind of measure or unit? I'm looking for inch.
Thank you.