![]() | Type | Description | ||
| Button as String | A string expression that indicates the name of the being clicked. The Button parameter does not include the HTML format. | |||
| Cancel as Variant | A boolean expression that indicates whether the default operation is executed or canceled. |
The following sample adds a new button 'sin' and execute the trigonometric sin function when 'sin' button is clicked:
Private Sub Form_Load()
With CalcCombo1
.Buttons = .Buttons + vbCrLf + "<b>sin<b>"
End With
End Sub
Private Sub CalcCombo1_ClickButton(ByVal Button As String, Cancel As Variant)
If (Button = "sin") Then
With CalcCombo1
.Execute Sin(.Caption)
End With
End If
End Sub