1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Excel VBAコース第2回内容

Last updated at Posted at 2019-04-13

全12回 Excel VBAコースの第2回の内容です。

#変数
・変数の宣言
・変数の型(すべて覚えなくてもOK)

型指定文字 保存できるデータ
Boolean True, False
Byte 0~255の整数
Integer -32,768~32,767の整数
Long -2,147,483,648~2,147,483,647の整数
Currency -922,337,203,685,477.5808 ~922,337,203,685,477.5807の固定小数点数
Single 負の値:約-3.4×10(38乗)~-1.4×10(-45乗)正の値:約1.4×10(-45乗)~1.8×10(38乗)
Double 負の値:約-1.8×10(308乗)~-4.0×10(-324乗)正の値:約4.9×10(-324乗)~1.8×10(308乗)
Date 日付:西暦100年1月1日~西暦9999年12月31日時刻:0:00:00 ~ 23:59:59
Object オブジェクト
Variant すべてのデータ

#繰り返し
・For ~ Next
(Do while ~ Loop)

下記のコードでは、メッセージボックスにiの値(0~9)が表示されます。

Sub 繰り返し()

  Dim i As Long

  For i = 0 To 9
    MsgBox(i)
  Next i

End Sub

#デバッグ②
・実行とステップ実行
・変数の中身の見方
・ローカルウィンドウ

1
1
1

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
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?