View Complete Thread | FoxWeb Forum Home
Search:
Date:    Msg ID:   
From:    Thread:   
Subject:   

Hello. I am having a hard problem setting a variable so I can capture it later and query a table. Here is the code using FoxWeb authenicate code to log in the user:

ClientLogin.FWX

      CASE Auth.NewLogin
       SET CENTURY ON
       IF USED('clients')
        SELECT clients
        USE
       ENDIF
       USE pbs!clients IN 0
       SELECT CLIENTS
       LOCATE FOR clients.userID = Auth.UserID
       pUser = ""
       pUserID = ""
       pUser = clients.clientid && unique client ID
       Session.SetVar(pUserID,pUser) && save unique id to var pUserID
       USE
       Response.Redirect("http://localhost/pbs/clienthome.fwx")

clienthome.fwx

<%
lcClientID = Session.GetVar(pUserID) && Error Here - Can't find var pUserID
USE c:\inetpub\wwwroot\data\pbs!vClientProfile NODATA SHARED IN 0  && local view
SELECT vClientProfile  && Select view
vClientID = lcClientID  && set value for parameratized view
=REQUERY()  && fetch record
%>

What am I doing wrong setting and getting a session variable?

Joe