Die beiden Buttons Ja und Nein werden mit dem Fragezeichen verknüpft. Der Benutzer muss die Frage beantworten. Die Antwort wird mit Hilfe einer Verzweigung ausgewertet. Im vorliegenden Programm werden lediglich zwei unterschiedliche Meldungen ausgegeben. Man könnte mit der Auswertung der beiden Antworten zwei unterschiedliche Abläufe einleiten.
Sub MsgBoxYesNo()
If MsgBox("Soll die Datei gesichert werden?", _
vbYesNo Or vbQuestion, "Sicherung") = vbYes Then
MsgBox "Sie wollen die Datei sichern"
Else
MsgBox "Sie wollen die Datei nicht sichern"
End If
End Sub
Buttons "Yes" and "No" with VBA in Microsoft Excel
Was the explanation to "Buttons "Yes" and "No" with VBA in Microsoft Excel"Helpful? Rate now:
More explanations too
- Portfolio analysis / BCG matrix
- Economic cycle
- Product life cycle
- Production factors (economics)
- Pricing strategies
- Matrix organization
- Organizational structure
- Multi-line system
- Legal transactions: form, nullity and contestability
- Economies of scale
- Accruals and deferrals
- Determination of sources of supply
- Process organization
- Staff line organization
- Pricing in the markets