「Excel VBA ユーザフォームを閉じさせない」の版間の差分
ナビゲーションに移動
検索に移動
(ページの作成:「==Excel VBA ユーザフォームを閉じさせない== Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer) If isRunning And CloseMode = vbF…」) |
|||
(同じ利用者による、間の1版が非表示) | |||
1行目: | 1行目: | ||
− | ==Excel VBA ユーザフォームを閉じさせない== | + | ==[[Excel VBA ユーザフォームを閉じさせない]]== |
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer) | Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer) | ||
− | If isRunning And CloseMode = | + | If isRunning And CloseMode = vbFormControl[[Menu]] Then |
− | If MsgBox("処理中です。本当に終了しますか?", vbQuestion Or vbYesNo) | + | If MsgBox("処理中です。本当に終了しますか?", vbQuestion Or vbYesNo) <> vbYes Then |
Cancel = 1 | Cancel = 1 | ||
End If | End If | ||
9行目: | 9行目: | ||
---- | ---- | ||
− | {{include_html banner_html, "!Excel"}} | + | {{include_html [[banner_html]], "!Excel"}} |
2020年2月16日 (日) 04:25時点における最新版
Excel VBA ユーザフォームを閉じさせない
Private Sub UserForm_QueryClose(Cancel As Integer, CloseMode As Integer) If isRunning And CloseMode = vbFormControlMenu Then If MsgBox("処理中です。本当に終了しますか?", vbQuestion Or vbYesNo) <> vbYes Then Cancel = 1 End If End If End Sub
{{include_html banner_html, "!Excel"}}
© 2006 矢木浩人