Can I reference a query from within a UDF?  I'm building a new shopping cart that has 
the items and quantities in a session query
(session.basket) and I want to total the number of items that are currently in the 
query from a UDF.  The query has a quantity field
and I want the UDF to be something like:

function BasketItemCount
{
  var totitems=0;
  for (i = 1; i lte session.basket.recordcount;  i = i + 1) {
   <!--- add the item quantity to the totitems here --->
   }
 return totitems;
}

Thanks,

--
Howie Hamlin - inFusion Project Manager
On-Line Data Solutions, Inc. - www.CoolFusion.com  - 631-737-4668 x101
inFusion Mail Server (iMS) - The Award-winning, Intelligent Mail Server
>>> Find out how iMS Stacks up to the competition: 
>http://www.coolfusion.com/imssecomparison.cfm


______________________________________________________________________
This list and all House of Fusion resources hosted by CFHosting.com. The place for 
dependable ColdFusion Hosting.
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to