[ 2 posts ]

alanpika_au

  • Joined: Mon Jan 24, 2011 3:19 pm
  • Posts: 1
  • Offline
  • Profile

how to reference original data in recordset

Post Posted: Mon Jan 24, 2011 3:24 pm
+0-
I'm using a local data source for my dataTable and i'd like each record in the recordSet to reference the real data as apposed to a shallow copy.

Alberto Santini

YUI Contributor

  • Offline
  • Profile
Tags:

Re: how to reference original data in recordset

Post Posted: Tue Jan 25, 2011 12:11 am
+0-
Hello alanpika_au.

http://developer.yahoo.com/yui/docs/YAH ... od_getData

For instance,

...
products = myDataTable.getRecordSet();
nProducts = products.getLength();
for (i = 0; i < nProducts; i = i + 1) {
prods[i] = products.getRecord(i).getData("symbol");
// myObject = products.getRecord(i).getData();
// then you can get data myObject.myProperty
...

Hope that helps,
IceBox
  [ 2 posts ]
Display posts from previous:  Sort by  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum