Here's my problem. I'm trying to add different security levels to my website by using session variables. I've got an updatable grid on my pages that I want only read only for some users and full access for others. The only way I could think of to make this possible is to make 2 data source names. I put the following if statement into global.asa:
Sub Application_OnStart
dim DSNname
if (session("Usr"
= "administrator"
then DSNname = "DSN=Access2ASP;"
else
DSNname = "DSN=ReadonlyDB;"
end if
Application("Connection2_ConnectionString"
= DSNname
Application("Connection2_ConnectionTimeout"
= 15
Application("Connection2_CommandTimeout"
= 30
Application("Connection2_CursorLocation"
= 3
Application("Connection2_RuntimeUserName"
= ""
Application("Connection2_RuntimePassword"
= ""
Problem is it always reads in the session variable as "". I believe this is because my session variable gets created on my 2nd page of my website. Is there a way to call the Application_onstart from my login page???
Thanks for any help.
Sub Application_OnStart
dim DSNname
if (session("Usr"
else
DSNname = "DSN=ReadonlyDB;"
end if
Application("Connection2_ConnectionString"
Application("Connection2_ConnectionTimeout"
Application("Connection2_CommandTimeout"
Application("Connection2_CursorLocation"
Application("Connection2_RuntimeUserName"
Application("Connection2_RuntimePassword"
Problem is it always reads in the session variable as "". I believe this is because my session variable gets created on my 2nd page of my website. Is there a way to call the Application_onstart from my login page???
Thanks for any help.