Question How do I view charachters ina font

osullivj35

New member
Joined
Jan 5, 2009
Messages
3
Programming Experience
Beginner
Hi,

Is there any way to display characters in a font in my win forms application. I'm looking for character map style functionality

Thanks,
Jerry
 
Assuming that you have the requisite Labels on your form:
VB.NET:
Private labels As Label() = {Me.label0, ... , Me.label255}

Private Sub Form1_Load(ByVal sender As Object, _
                       ByVal e As EventArgs) Handles MyBase.Load
    For index As Integer = 0 To 255
        Me.labels(index).Text = Convert.ToChar(index)
    Next
End Sub
That will display the characters with Unicode values 0 to 255 in your Labels. You can then simply set the Font property of each label to whatever Font you want to display.
 
Perfect thanks..


I now need to exclude all the square characters that may be in a font..Any ideas I tried to do a string compare but no luck

Thanks,
Jerry
 
Hi

Thanks for that.

Is there any way of identifying these characters that 'that have no visual representation'

Thanks,
J
 
They will be the ones that are displayed as a box in the UI. It will vary from font to font, depending on its specific purpose, but some will always be unable to be displayed. Try a bit of testing.
 
Back
Top