Card suit symbol in user form label

mikerickson

MrExcel MVP
Joined
Jan 15, 2007
Messages
24,355
For a card playing game, I'm trying to put a Clubs symbol in a user form Label. (A Clubs symbol looks like a 3 leaf clover).

So I filled some cells with =CHAR(ROW()), tried different fonts, and found that =CHAR(167) with the Symbol font gives me what I want.

Code:
With Range("R2")
    .Font.Name = "Symbol"
    .Value = Chr(167)
End With

But when I ran this in the user form code module
Code:
Private Sub UserForm_Click()
    With Label1
        .Font.Name = "Symbol"
        .Caption = Chr(167)
        
        MsgBox .Font.Name: Rem returned "Symbol"
    End With
End Sub
, I got a capital beta, ß.


As a check, I created a rectangle in a worksheet, ran this
Code:
With ActiveSheet.Shapes(1)
    .TextFrame.Characters.Font.Name = "Symbol"
    .TextFrame.Characters.Text = Chr(167)

    MsgBox .TextFrame.Characters.Font.Name: Rem returned Symbol
End With
And got a doubled downward arrow. (Which, when copy pasted into a cell became the desired Club symbol)

I don't understand why this his happening.
Does anybody have any thoughts?
Does anybody know some other way to put the Club symbol (and hearts, spades, diamonds) into a user form label?
 
Last edited:

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
This worked for me.
Code:
Private Sub UserForm_Initialize()
With Label1
    .Font.Size = 16
    .Caption = ChrW(9827) & " " & ChrW(9824) & " " & ChrW(9830) & " " & ChrW(9829)
End With
End Sub
 
Upvote 0
Sweet!
Thanks MickG.

I'm still puzzled by the different results of font name Symbol, but ChrW should get my form going.

Thanks!
 
Upvote 0

Forum statistics

Threads
1,223,236
Messages
6,170,915
Members
452,366
Latest member
TePunaBloke

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top