devxlogo

Is There a GoTo Statement in ASP?

Is There a GoTo Statement in ASP?

Question:

Is GoTo a valid Statement in ASP?

I need to do something like this:

If x=y then  Goto THEREend ifTHERE: bla bla bla

Answer:

There is no GoTo statement in ASP. You shouldn’t use a GoTo statement in your code, it leads to very messy spaghetti code.

Instead, place your code in a subroutine and call it:

if x = y then   call MyRoutine arg1, arg2 ...end if

devx-admin

Share the Post: