J
JamesJ
I'm using the following to toggle initiate bold and/or underline in a
RichText control. Someone in the activex newsgroup was kind
enough to give me this code.
Private Sub Form_KeyUp(KeyCode As Integer, Shift As Integer)
If KeyCode = vbKeyB And Shift = 2 Then
Me!axcRichText.SelBold = Not Me!axcRichText.SelBold
End If
If KeyCode = vbKeyU And Shift = 2 Then
Me!axcRichText.SelUnderline = Not Me!axcRichText.SelUnderline
End If
End Sub
What I would like to have is an indication on the form whether bold and/or
underline
is active by changing a labels border style to transpaerant if false and
solid if true.
I know I can set the label's border style to solid when the KeyCode is fired
but don't know how to toggle it back to transparent.
Any help will be appreciated.
Thanks,
James
RichText control. Someone in the activex newsgroup was kind
enough to give me this code.
Private Sub Form_KeyUp(KeyCode As Integer, Shift As Integer)
If KeyCode = vbKeyB And Shift = 2 Then
Me!axcRichText.SelBold = Not Me!axcRichText.SelBold
End If
If KeyCode = vbKeyU And Shift = 2 Then
Me!axcRichText.SelUnderline = Not Me!axcRichText.SelUnderline
End If
End Sub
What I would like to have is an indication on the form whether bold and/or
underline
is active by changing a labels border style to transpaerant if false and
solid if true.
I know I can set the label's border style to solid when the KeyCode is fired
but don't know how to toggle it back to transparent.
Any help will be appreciated.
Thanks,
James