Hmm... hopefully someone can kick me in the right direction on this one:

I have a struct (RpcStruct) and I want to insert multiple arrays 
(RpcArray) in it which are filled by a for each loop. (number of arrays 
is variable)

If I clear the array each time at the end of the loop with .Clear() it 
removes the array data which is already added to the sList struct, so 
thats not what I want, anyone has an idea how to cope with this?

Thanks a lot in advance.
I'm running Gambas 2.11

Regards,
Ron_2nd.

   DIM aTmpArray AS NEW RpcArray
   DIM sList AS NEW RpcStruct

   rResult = Main.hDB.Exec("SELECT * FROM devices")

   FOR EACH rResult

     aTmpArray.Add(rResult!name, XmlRpc.xString)
     aTmpArray.Add(rResult!value, XmlRpc.xString)
     aTmpArray.Add(rResult!label, XmlRpc.xString)
     sList.Add(rResult!name, aTmpArray, XmlRpc.xArray)

    ' aTmpArray.Clear()

   NEXT

   hXMLRPC.SetReply(sList)

------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to