Logical comparison not working in VBA ????
Pasted below is an excerpt from VBA code I'm working on. For some reason it
will not properly execute this logic. When StopLong = 0.085 it cannot make
the first If..then logical comparison. Passes right over it. Have been using
VBA for 10years and have no clue whats going on.
For BuyLim = 0.001 To 0.07 Step 0.002
For GainSell = 0.001 To 0.08 Step 0.003
For StopLong = 0.001 To 0.09 Step 0.003
If StopLong = 0.085 Then
If GainSell = 0.001 Then
If BuyLim = 0.001 Then
weird = False
End If
End If
End If
Next
Next
Next
|