LoginSignup
0
3

More than 5 years have passed since last update.

【初心者の質問】戻り値について

Last updated at Posted at 2018-08-27

VBAで戻り値を返すにはSubではなく、Functionプロシージャーを使うとあり、

VBA関数は、処理の材料となる値:引数と、結果の値:戻り値が返ります。
とあります。

Sub sumple()
 Dim i As Integer
 i = Msgbox("今日は晴れですか",vbyesno,"今日の天気は")
End Sub

上記で、Msgbox関数の戻り値がiの変数に代入ということですよね。

この場合Subプロシージャで記述するのはどうしてでしょうか?

0
3
3

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
3