Hi,

I'm going to develop a solution in vbscript and I have chosen to use
Class in vbscript, but my question is the following:

Is there any reason not to prefer Classes use instead of a basical
solutions (functions, etc..) ?

Thx for your time,

Vince.

Re: Class in vbscript by mayayana

mayayana
Tue Sep 16 09:46:05 CDT 2003


>
> I'm going to develop a solution in vbscript and I have chosen to use
> Class in vbscript, but my question is the following:
>
> Is there any reason not to prefer Classes use instead of a basical
> solutions (functions, etc..) ?

"develop a solution"? That means you're going to write a script?
Hopefully you can "leverage this documentation":

A class is just a way to "encapsulate" the code. Only public items
in the class are visible to the outside, so the class becomes an object,
independent from the rest of the code in your script. That can be handy
when you have generic code that you will have occasion to reuse. You
can write functionality in the class, provide public methods to use
that functionality, and then just paste the class into any script where
you want those functions.



Re: Class in vbscript by Vince

Vince
Tue Sep 16 11:07:38 CDT 2003

Thx for answering mayayana but I already know what a class is, I just
would like to know if use of class is recommanded when you work on high
frequented web site.

Isn't it better keeping public functions usage instead of dealing with
objects (classes) when we speak about performance ?

I mean no risk of performance loss by using classes ?

Thx for help.

Regards,

Vince.


mayayana wrote:
>>I'm going to develop a solution in vbscript and I have chosen to use
>>Class in vbscript, but my question is the following:
>>
>>Is there any reason not to prefer Classes use instead of a basical
>>solutions (functions, etc..) ?
>
>
> "develop a solution"? That means you're going to write a script?
> Hopefully you can "leverage this documentation":
>
> A class is just a way to "encapsulate" the code. Only public items
> in the class are visible to the outside, so the class becomes an object,
> independent from the rest of the code in your script. That can be handy
> when you have generic code that you will have occasion to reuse. You
> can write functionality in the class, provide public methods to use
> that functionality, and then just paste the class into any script where
> you want those functions.
>
>


Re: Class in vbscript by Jon

Jon
Tue Sep 16 12:19:25 CDT 2003


"Vince" <vsld@free.fr> wrote in message
news:3f670200$0$27598$626a54ce@news.free.fr...
> Hi,
>
> I'm going to develop a solution in vbscript and I have chosen to use
> Class in vbscript, but my question is the following:
>
> Is there any reason not to prefer Classes use instead of a basical
> solutions (functions, etc..) ?
>


Classes are great for re-use, but will not work on version < 5






Re: Class in vbscript by Mythran

Mythran
Tue Sep 16 12:54:13 CDT 2003

Serverside, you won't see a difference when using classes unless you persist
them. (don't time them either).

Clientside, don't use em on internet sites ;p


Some advice...

Mythran


"Jon" <no-email@this.time> wrote in message
news:bk7gms$jd$1@titan.btinternet.com...
>
> "Vince" <vsld@free.fr> wrote in message
> news:3f670200$0$27598$626a54ce@news.free.fr...
> > Hi,
> >
> > I'm going to develop a solution in vbscript and I have chosen to use
> > Class in vbscript, but my question is the following:
> >
> > Is there any reason not to prefer Classes use instead of a basical
> > solutions (functions, etc..) ?
> >
>
>
> Classes are great for re-use, but will not work on version < 5
>
>
>
>
>