Are you sure this is all there is to it? Just that code alone should return
true, but if you're assinging i and j by some other means, it's likely that
one of them is a string and one is an integer, or something along those
lines. Doing this will take care of it though:
If CInt(i) = CInt(j) Then...
Depending on what kind of values you're using, you may want CLng to avoid an
overflow, i.e.
i = 32938493
j = 32938493
If CInt(i) = CInt(j) Then
'''Will cause an overflow
http://msdn.microsoft.com/library/de...svariables.asp
Ray at work
"K" <n_***@videotron.ca> wrote in message
news:Mb*******************@wagner.videotron.net...
hi guys,
I am doing this here:
dim i
dim j
i = 10
j = 10
If i = j then
But it is giving me a false result...
Any ways to do this comparison so it gives me the proprer result?
Thanx.