Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Can we change/handle property of Push Button in multi record block?
sajjadawan_at_hotmail.com wrote:
> Can we change/handle property of Push Button in multi record block (table
> window) Individually. For example for first row its label is "ADD" and for the
> second row it is "Remove".
>
I had this problem also, but there is no way to do this. The only thing you can
do
is set a visual attribute for the current record.
But you can make a very tricky hack...
First you position a button next to every row of the record block. It will then
look
like this in your form:
Field 1 1 Field 1 2 Field 1 3 ... Button 1 Field 2 1 Field 2 2 Field 2 3 ... Button 2 Field 3 1 Field 3 2 Field 3 3 ... Button 3...
Make sure that the buttons are NOT part of the multi record block. The must have
their
own block and you have to identify them individually with individual names.
Second you write a PRE-TEXT-ITEM or PRE-BLOCK-ITEM trigger doing the following:
1) Determine the number of the entered row (GET_BLOCK_PROPERTY) 2) Check how many rows have already been srolled down (GET_BLOCK_PROPERTY) 3) subtract the numbers received with (1) and (2). This is the number of thebutton corresponding
to the entered row.
4) Set the properties of the button to whatever the button in the active row
should do. (SET_ITEM_PROPERTY)
You also have to make sure that the code attached to each buttons "knows" what to
do! You can do
this by checking the state of the button via GET_ITEM_PROPERTY or by using a
variable remembering the
number of the active row and branching via an IF-ELSIF-ELSE.
Marcel Received on Mon May 04 1998 - 00:00:00 CDT
![]() |
![]() |