A script-enabled browser is required for this page to function properly.

GET_RADIO_BUTTON_PROPERTY Built-in

Description

Returns information about a specified radio button.

Syntax

FUNCTION GET_RADIO_BUTTON_PROPERTY
(item_id ITEM,
button_name
VARCHAR2,
property
NUMBER);

FUNCTION GET_RADIO_BUTTON_PROPERTY(
item_name VARCHAR2,
button_name
VARCHAR2,
property
NUMBER);

Built-in Type unrestricted function

Returns VARCHAR2

Enter Query Mode yes

Parameters

item_id 
 
Specifies the radio group item ID. Oracle Forms assigns the unique ID at the time it creates the object. Use the FIND_ITEM Built-in to return the ID to an appropriately typed variable. The data type of the ID is ITEM.
 
item_name 
 
Specifies the name of the radio group. The radio group is the owner or parent of its subordinate radio buttons. The data type of the name is VARCHAR2.
 
button_name 
 
Specifies the name of the radio button whose property you want. The data type of the name is VARCHAR2.
 
property 
 
Specifies the property for which you want the current state. The possible property constants you can indicate are as follows:

BACKGROUND_COLOR The color of the object's background region.

ENABLED Returns the VARCHAR2 string TRUE if property is set to Yes, and the VARCHAR2 string FALSE if property is set to No.

FILL_PATTERN The pattern to be used for the object's fill region. Patterns are rendered in the two colors specified by Background Color and Foreground Color.

FONT_NAME The font family, or typeface, that should be used for text in the object. The list of fonts available is system-dependent.

FONT_SIZE The size of the font, specified in points.

FONT_SPACING The width of the font, that is, the amount of space between characters (kerning).

FONT_STYLE The style of the font.

FONT_WEIGHT The weight of the font.

FOREGROUND_COLOR The color of the object's foreground region. For items, the Foreground Color attribute defines the color of text displayed in the item.

HEIGHT Returns the height of the radio button. The value is returned as a VARCHAR2 and is expressed in the units as set for the form by the form module Coordinate System property.

LABEL Returns the actual string label for that radio button.

PROMPT_FILL_PATTERN The pattern to be used for the object's fill region. Patterns are rendered in the two colors specified by Background Color and Foreground Color.

PROMPT_FONT_NAME The font family, or typeface, that should be used for text in the object. The list of fonts available is system-dependent.

PROMPT_FONT_SIZE The size of the font, specified in points.

PROMPT_FONT_SPACING The width of the font, that is, the amount of space between characters (kerning).

PROMPT_FONT_STYLE The style of the font.

PROMPT_FONT_WEIGHT The weight of the font.

PROMPT_FOREGROUND_COLOR The color of the object's foreground region. For items, the Foreground Color attribute defines the color of text displayed in the item.

VISIBLE Returns the VARCHAR2 string TRUE if property is set to Yes, returns and the VARCHAR2 string FALSE if property is set to No.

VISUAL_ATTRIBUTE Returns the name of the visual attribute currently in force. If no named visual attribute is assigned to the radio button, returns CUSTOM for a custom visual attribute or DEFAULT for a default visual attribute.

WIDTH Returns the width of the radio button, including the label part. The value is returned as a VARCHAR2 and is expressed in the units as set for the form by the form module Coordinate System property.

WINDOW_HANDLE Returns the a unique internal VARCHAR2 constant that is used to refer to objects. Returns the number 0 if the platform is not Microsoft Windows.

X_POS Returns the x coordinate that reflects the current placement of the button's upper left corner relative to the upper left corner of the canvas. The value is returned as a VARCHAR2 and is expressed in the units defined by the form module Coordinate System property.

Y_POS Returns the y coordinate that reflects the current placement of the button's upper left corner relative to the upper left corner of the canvas. The value is returned as a VARCHAR2 and is expressed in the units defined by the form module Coordinate System property.

GET_RADIO_BUTTON_PROPERTY Examples

/*

** Built-in: GET_RADIO_BUTTON_PROPERTY
** Example: Determine whether a given radio button is
** displayed and has a particular visual
** attribute.
*/
DECLARE
it_id Item;
disp VARCHAR2(5);
va_name VARCHAR2(40);
BEGIN
it_id := Find_Item('My_Favorite_Radio_Grp');
disp := Get_Radio_Button_Property( it_id, 'REJECTED', VISIBLE);
va_name := Get_Radio_Button_Property( it_id, 'REJECTED',
VISUAL_ATTRIBUTE);

IF disp = 'TRUE' AND va_name = 'BLACK_ON_PEACH' THEN
Message('You win a prize!');
ELSE
Message('Sorry, no luck today.');
END IF;
END;