Excel VBA (Macro) Single Line If Statement - Code Included

Опубликовано: 12 Октябрь 2024
на канале: EverydayVBA
818
3

Grab the Free VBA Quick Reference Guide
https://www.chrisjterrell.com/excel-v...
In this Video we review the Single Line If Statement.

Which is If [criteria] then [sigle line of code]

Code:
===============
Sub SingleIf()

mbox = MsgBox("Check Yes or No", vbYesNo)

If mbox = vbYes Then MsgBox "You Clicked Yes"

End Sub