I would like to be able to get the type of object that a session variable
contains (for example, determine whether it is a string, integer, single
precision floating point, ADODB.Recordset, etc...)

I need to know this for a ASP <----> ASP.NET session management script I am
writing. I would like to be able just to copy strings and numbers. I
already have code that does this, but I don't want my script to blow up when
it finds a recordset in the session object!

Is there any easy way to detect the object type in ASP?

Re: ASP and session object (get type) by James

James
Mon Jun 21 14:50:03 CDT 2004

You're probably going to be told at least once in this thread that you
shouldn't contain recordsets (or any objects) in a Session variable. I
suspect there are better ways to solve the problem to begin with.


"ASP.Confused" <anonymous@> wrote in message
news:uly5%23f8VEHA.3512@TK2MSFTNGP12.phx.gbl...
> I would like to be able to get the type of object that a session variable
> contains (for example, determine whether it is a string, integer, single
> precision floating point, ADODB.Recordset, etc...)
>
> I need to know this for a ASP <----> ASP.NET session management script I
am
> writing. I would like to be able just to copy strings and numbers. I
> already have code that does this, but I don't want my script to blow up
when
> it finds a recordset in the session object!
>
> Is there any easy way to detect the object type in ASP?
>
>



Re: ASP and session object (get type) by Chris

Chris
Mon Jun 21 15:03:53 CDT 2004

http://www.haneng.com/FunctionSearch.asp?s=IsObject

and

http://www.haneng.com/FunctionSearch.asp?s=TypeName

TypeName on an recordset = "Recordset" [I think]

Try it and see what you get.

Chris.

"ASP.Confused" <anonymous@> wrote in message news:uly5%23f8VEHA.3512@TK2MSFTNGP12.phx.gbl...
I would like to be able to get the type of object that a session variable
contains (for example, determine whether it is a string, integer, single
precision floating point, ADODB.Recordset, etc...)

I need to know this for a ASP <----> ASP.NET session management script I am
writing. I would like to be able just to copy strings and numbers. I
already have code that does this, but I don't want my script to blow up when
it finds a recordset in the session object!

Is there any easy way to detect the object type in ASP?




Re: ASP and session object (get type) by Mark

Mark
Mon Jun 21 15:06:06 CDT 2004

See the VBScript TypeName() function.

--
Mark Schupp
Head of Development
Integrity eLearning
www.ielearning.com


"ASP.Confused" <anonymous@> wrote in message
news:uly5%23f8VEHA.3512@TK2MSFTNGP12.phx.gbl...
> I would like to be able to get the type of object that a session variable
> contains (for example, determine whether it is a string, integer, single
> precision floating point, ADODB.Recordset, etc...)
>
> I need to know this for a ASP <----> ASP.NET session management script I
am
> writing. I would like to be able just to copy strings and numbers. I
> already have code that does this, but I don't want my script to blow up
when
> it finds a recordset in the session object!
>
> Is there any easy way to detect the object type in ASP?
>
>



Re: ASP and session object (get type) by Aaron

Aaron
Mon Jun 21 15:28:54 CDT 2004

> I would like to be able to get the type of object that a session variable
> contains (for example, determine whether it is a string, integer, single
> precision floating point,

Maybe this article will help a bit,
http://www.aspfaq.com/2524

> ADODB.Recordset, etc...)

DON'T DO THIS! http://www.aspfaq.com/2053

--
http://www.aspfaq.com/
(Reverse address to reply.)