Re: Item

From: <pberetta_at_my-deja.com>
Date: Fri, 15 Oct 1999 00:37:24 GMT
Message-ID: <7u5t03$hei$1_at_nnrp1.deja.com>


If you are looping a reasonably small number of times (your example shows 4) then a construct such as

   IF cVal.number = 1 THEN

      :myitem1 := cVal.databaseValue;
   ELSIF cVal.number = 2 THEN

      :myitem2 := cVal.databaseValue;
   ELSIF cVal.number = 3 THEN

      :myitem3 := cVal.databaseValue;
   ELSIF cVal.number = 4 THEN

      :myitem4 := cVal.databaseValue;
   END IF; should solve your problem. It's not elegant, but it should work.

In article <11f733ec.053780fb_at_usw-ex0101-002.remarq.com>,   peterlon <andrea.peterlongoNOanSPAM_at_infotn.it.invalid> wrote:
> I want to populate an "array" of button and text item with data
fetched
> from a cursor using a kind of for loop.
> Say
> cursor cItem is ....
> cVal cItem%rowtype
> ....
>
> open cItem;
> for i in 1..4 loop
> fetch cItem into cVal
> /* here I assign my button label: it works*/
> set_item_property('mybutton'||cVal.number, LABEL,
> cVal.databaseString);
> /* here I would lik to assign my text item: it doesn't work */
> ...some kind of...
> myitem||cVal.number := cVal.databaseValue
> loop
> close cItem
>
> Is there somebody that can tell me if and how it is possible to assign
> a value to an item whose reference name is to be built at runtime?
>
> Thank you in advance,
>
> Andrea
>
> * Sent from RemarQ http://www.remarq.com The Internet's Discussion
Network *
> The fastest and easiest way to search and participate in Usenet -
Free!
>
>

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Fri Oct 15 1999 - 02:37:24 CEST

Original text of this message