Avatar of Alex E.
Alex E.

asked on 

VBSCRIPT in Page Load C# ASP.NET

I have this VBscript code in the head section of an asp.net c# form for a webapp:

   <script language="vbscript" type="text/vbscript">

Dim myString, valuecn, cn, stringvalue

valuecn = Request.QueryString("valuecn")

if valuecn = "" then valuecn = "inactivo" End If

If valuecn = "inactive" then

Response.Redirect("inactive.aspx")

End if

</script>

Open in new window


How can we do to execute that in the page load of asp.net c# code behind?

Because if you run the page never redirect to inactive.aspx

Thank you
ASP.NET.NET ProgrammingC#VB Script

Avatar of undefined
Last Comment
Alex E.

8/22/2022 - Mon