回答編集履歴

3

MsgBox (26.26 - 26)追記

2020/06/24 02:31

投稿

tosi
tosi

スコア553

test CHANGED
@@ -48,6 +48,8 @@
48
48
 
49
49
  '-----------------------------------
50
50
 
51
+ MsgBox (26.26 - 26)
52
+
51
53
  End Sub
52
54
 
53
55
  ```

2

varへ変更

2020/06/24 02:31

投稿

tosi
tosi

スコア553

test CHANGED
@@ -18,31 +18,31 @@
18
18
 
19
19
  '-----------------------------------
20
20
 
21
- Dim dblA As Range
21
+ Dim varA As Range
22
22
 
23
- Dim dblB As Range
23
+ Dim varB As Range
24
24
 
25
-
26
25
 
27
- Set dblA = Range("A1")
28
26
 
29
- Set dblB = Range("B1")
27
+ Set varA = Range("A1")
30
28
 
31
- dblA = 0.3
29
+ Set varB = Range("B1")
32
30
 
33
- dblB = 0.1 + 0.2
31
+ varA = 0.3
34
32
 
35
-
33
+ varB = 0.1 + 0.2
34
+
35
+
36
36
 
37
37
  '計算差額のチェック
38
38
 
39
- If dblA.Value = dblB.Value Then
39
+ If varA.Value = varB.Value Then
40
40
 
41
41
  MsgBox "一致"
42
42
 
43
43
  Else
44
44
 
45
- MsgBox "不一致 ⇒ " & dblA & " - " & dblB
45
+ MsgBox "不一致 ⇒ " & varA & " - " & varB
46
46
 
47
47
  End If
48
48
 

1

変更

2020/06/24 01:49

投稿

tosi
tosi

スコア553

test CHANGED
@@ -28,15 +28,13 @@
28
28
 
29
29
  Set dblB = Range("B1")
30
30
 
31
-
32
-
33
31
  dblA = 0.3
34
32
 
35
33
  dblB = 0.1 + 0.2
36
34
 
37
35
 
38
36
 
39
- '計算差額と確認差額のチェック
37
+ '計算差額のチェック
40
38
 
41
39
  If dblA.Value = dblB.Value Then
42
40