Sorry, but this doesn't make sense to me. Can you post a better pseudo-code example? If you have something that needs to execute before something else happens, code the first "thing" as a method that returns a value. Test the value, then move forward or not.
There should never be a need to do what you're asking to do.
OK, I've already solved that, it was just an error in code... But however, I'll ask a different way - do we have something like timer in asp.net 2 ? Just if I want to refresh the page in some intervals?
so you want to auto refresh the page at set times?
Best way to do it is to put it in the META tag. It is the same technique as an auto redirect to another page, only this time you are reloading your own page.
You can either code this in the markup when you design it or you can add it later in code when you want it.
in code you need to add the following line
Response.Write("<Meta http-equiv='REFRESH' content='20;URL=mypage.aspx' />");
and in markup you just need
<Meta http-equiv='REFRESH' content='20;URL=mypage.aspx' />
the 20 means 20 seconds, so put your own time in there. It is as simple as that