HI,
I have a macro that places a values into a variable named "Yield". The value is safely passed to the variable. When the value is later posted to a different cell, the value is slightly different. When using the watch window, I see the variable correctly housing the value, even after posting it to the cell.
By example:
What causes it and how do I correct this?
TIA
I have a macro that places a values into a variable named "Yield". The value is safely passed to the variable. When the value is later posted to a different cell, the value is slightly different. When using the watch window, I see the variable correctly housing the value, even after posting it to the cell.
By example:
Code:
...
Dim Yield as Single
.
.
.
Yield = ActiveCell.Offset(0, 1).Value [COLOR="Red"] 'At this point the value is 0.4[/COLOR]
.
.
.
ActiveCell.Offset(-2, 1) = Yield [COLOR="red"] ' Suddenly, the value is 0.400000005960464 when viewed in the cell.[/COLOR]
...
What causes it and how do I correct this?
TIA