Thanks Jure - the thlot plickens. I had tried getting the Ubounds of obj.Items and it returns the correct values to indicate that there are 5 products with 8 "fields". And yet trying to reference obj.Items(0,0) or obj.Items(1,1) etc throws an error.

I tried your suggestion of:
Public Property Let Items(Param)
   cvArrItems = Param
   response.write "<p>cvArrItems(1,0): " & cvArrItems(1,0) & "</p>"
End Property

which displays the correct output.  Then I tried:

Public Property Get Items
        response.write "<p>Get Items, cvArrItems(1,0): " & cvArrItems(1,0) & "</p>"
        Items = cvArrItems
        response.Write("<p>Get Items, Items(1,0): " & Items(1,0) & "</p>")
End Property

The first output of cvArrItems(1,0) displays correctly but the output of Items(1,0) throws the same old error: Wrong number of arguments or invalid property assignment: 'Items'
Yet there is no error thrown with the line above which assigns cvArrItems to Items.


All thoughts much appreciated,

Clancy


From: "Jure Spik" <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: [wdvltalk] Re: ASP Arrays OO
Date: Thu, 12 Aug 2004 15:54:16 +0100

Sorry I couldn't be of more help. Maybe you could try gett ing the
UBound(obj.Items, 1) and UBound(obj.Items, 2) to see how many items there
are (if any) in the array. If there are none I guess the object 'loses' them
somewhere in the process. Maybe if you would modify the property Set Items
to write out this.Items(0, 0) you would know if they get transferred ok:


Public Property Let Items(Param)
  cvArrItems = Param
  Response.Write(cvArrItems(0, 0))
End Property


Regards, Jure

----- Original Message -----
From: "Clancy Jones" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, August 11, 2004 11:31 PM
Subject: [wdvltalk] Re: ASP Arrays OO


> Thanks guys. I'm still not convinced that I should be declaring the OO
> array any differently than I am already. I'm basing this on the fact that
> isArray(gvobjCart.Items) returns true and I can loop through
gvobjCart.Items
> by...
>
> For Each gvstrElement in gvobjCart.Items
> response.write "<P>gvstrElement: " & gvstrElement
> Next
>
> ...which iterates through all the "fields" for each "record" and then
moves
> to the next "record" and does the same.
>
> So I would think that gvobjCart.Items IS an array - it's just that I don't
> seem to be able to reference it in the normal way. Bearing in mind also
> that if I use a normal variable and assign the recordset to it -
everything
> works fine. ie. I don't have to declare garrCart as an array...
>
> Dim garrCart
> garrCart = dbRS.GetRows()
>
> ...works fine.
>
> I don't know, maybe you are right Jure, maybe it is something to do with
> explicitly creating clsCart.Items as an array in the class. But I have
> tried playing around with that without success.
>
> Any other clues?
>
> Thanks a lot,
>
> Clancy





____ � The WDVL Discussion List from WDVL.COM � ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED]
Send Your Posts To: [EMAIL PROTECTED]
To set a personal password send an email to [EMAIL PROTECTED] with the words: "set WDVLTALK pw=yourpassword" in the body of the email.
To change subscription settings to the wdvltalk digest version:
http://wdvl.internet.com/WDVL/Forum/#sub


________________  http://www.wdvl.com  _______________________

You are currently subscribed to wdvltalk as: [EMAIL PROTECTED]
To unsubscribe send a blank email to %%email.unsub%%

To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016

Please include the email address which you have been contacted with.


_________________________________________________________________
There�s never been a better time to get Xtra JetStream @ http://xtra.co.nz/jetstream



____ � The WDVL Discussion List from WDVL.COM � ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED] Send Your Posts To: [EMAIL PROTECTED]
To set a personal password send an email to [EMAIL PROTECTED] with the words: "set WDVLTALK pw=yourpassword" in the body of the email.
To change subscription settings to the wdvltalk digest version:
http://wdvl.internet.com/WDVL/Forum/#sub


________________  http://www.wdvl.com  _______________________

You are currently subscribed to wdvltalk as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]

To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016

Please include the email address which you have been contacted with.



Reply via email to