p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   Classic ASP Basics (http://p2p.wrox.com/forumdisplay.php?f=61)
-   -   How to change ASP variable in VBScript (http://p2p.wrox.com/showthread.php?t=69991)

jimusa August 11th, 2008 10:47 AM

How to change ASP variable in VBScript
 
Hi Friends,

I created an asp file with some variables.
I declare status variable and assigned a default value.
Dim STO
STO ="Online"

I want to change STO in VA script logevent procedure.

I am trying to use set as <% set STO = "new value" %>

It does not work.

Every Experts, How to change ASP variable in VBScript?

Thanks,


New web person

**********source code***********
<%@ Language=VBScript %>
<html>
<head>
<title>TEST
</title>
</head>
<body bgcolor="white" >

<%
Dim GUIPar
Dim GUIPar2
Dim STO
STO ="Online"
GUIPar = Request.QueryString("para1")

response.write "<center><b>Status :</b>"&STO&"&nbsp&nbsp;"&now()&"<br></center>"
GUIPar ="00000001"
if cstr(GUIPar) ="" or IsNull( GUIPar ) then
Response.Redirect "http://localhost/error1.asp"
end if
%>

<center>
<p>xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

<script Language="VBScript">

Proxy.CreateInstance
dim GUID
dim objCurrentEntity
dim x
x =0

GUID = "{<%=GUIPar%>}"


Sub Proxy_OnLogon
    im st
    MsgBox "Successful Logon"
   st = Proxy.IsLoggedOn

if st = False then

   <% set STO = "Offline Service" %>
end if


End Sub

</script>
</body>
</html>

jimusa

mat41 August 13th, 2008 07:08 PM

The 'Set' is not neccesary. Change:

set STO = "new value"

To:

STO = "new value"

Wind is your friend
Matt
www.elitemarquees.com.au


All times are GMT -4. The time now is 06:48 PM.

Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.