RE: How can i test for this?
you could as Paul Hastings suggested (and as I typically suggest) use #structkeyexists(session.auth,100824)# Ahem g It was me, not Paul who suggested that Cheers Phil [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: How can i test for this?
I have a variable in a struct called session.auth that is related tothe id of the article the user is seeing.If the variable#session.auth.100824# exists, the user can visit article 100824 otherwise he's deniedaccess. How can I check that this variable exists?I have tried thefollowing and it throws an error, saying that isdefined has to have a syntacticallyvalid variable name: Where did I get it wrong please? Here's what I've put that throws an error: cfif isdefined(Session.auth[#articleid#]) you're in cfelse you're out /cfifInstead of using isDefined() on a key, you should use StructKeyExists()cfif StructKeyExists(Session.auth, articleID)That should do what you wantHTH [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]
RE: How can i test for this?
Oh well DER!!!#structkeyexists()#I knew about that.I DID!!!Ihadmomentarily forgotten that's all. Thanks folks.blush /me beats himself up for not remembering that! Cheers,Michael KearWindsor, NSW, AustraliaAFP Webworks.-Original Message-From: S. Isaac Dealey [mailto:[EMAIL PROTECTED] could as Paul Hastings suggested (and as I typically suggest) use#structkeyexists(session.auth,100824)# [Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]