Should be easy enough to figure out - debug and step through your
code.

I see one of only two possibilities:
1) sdr.Read() is returning false, so the while loop doesn't even get
entered.
2) percent is not between 0 and 1.

Stepping through your code will tell you which it is.

On Mar 18, 6:41 am, Jeena Ajiesh <[email protected]> wrote:
> Hi all,
> this may be a small error,
> anyway the problem is even though the condition is true, its not hitting.
> I'm retrieving some values from database and storing it in variable.
> Along with that,I'm comparing the retrieved value with another variable.
> Even if its true, its not going inside if loop.
> Can anyone find out that small error.
>
> My Code is as follows
>
> while sdr.Read()
>     from=sdr(0)
>     to=sdr(1)
>     name=sdr(2)
>     desc=sdr(3)
>       if (percent>=from) And (percent<=to)
>          txtname.text=name          //These r not executed.....
>          txtdesc.text=desc
>       End If
> End While
> Im doing it in Asp.net,vs2005
> --
> ****************
> Regards,
> ♪♥♫♥Ĵєєήǎ ♫♥♪♥
> Email: [email protected]
>          [email protected]
>          [email protected]

Reply via email to