Hi all,

I have problem getting the column name from grid. what i want to achieve is if user click one of value on the grid it will display the details. In order to filter which details display to the users, i need the column name that user click. I already set the grid and column name and i tried using this api_component.getclickgridcolumnname, but it return nothing.

all i need is how to tell which column was user click, so i can display the correct details ( each column on the grid will display different details ).

and here are my script ( the v_id always returns null value) :

PROCEDURE SHOW_LIST_DETAIL IS

  v_gridName            varchar2(1000); 
  v_datasourceName      varchar2(1000);
  v_pqcode              varchar2(30);
  v_prcode              varchar2(30);
  v_row                 API_DATASOURCE.TT_ROW;
  v_columns             API_DATASOURCE.TT_COLUMNS;
  v_columnName          varchar2(255);
  v_id varchar2(200);
 BEGIN
  v_gridName        := API_APPLICATION.GETFOCUSEDCOMPONENT;
  v_datasourceName  := API_COMPONENT.GETDATASOURCE(v_gridName);       
  v_row             := API_DATASOURCE.GETROW(v_datasourceName);       
  v_columns         := API_DATASOURCE.GETCOLUMNNAMES(v_datasourceName);        
  ---
  API_APPLICATION.SHOWPOPUPMESSAGE('Grid ' || v_gridName);
  v_id := API_COMPONENT.GETCLICKEDGRIDCOLUMNNAME(v_gridName);
  API_APPLICATION.SHOWPOPUPMESSAGE('Test' || v_id);

END;

asked 19 Dec '13, 05:44

Huwardi's gravatar image

Huwardi
1110
accept rate: 0%


Hi,

Are you clicking a grid column header or a component existing in the grid column? The api_component.getclickgridcolumnname API returns the name of the last clicked grid column header. For instance, if your grid design XML is like:

<grid name="grid1" datasource="yourDS">
  <column name="column1" headerLabel="First Name">
   ...

if the last clicked grid column header is the "First Name" column, the api_component.getclickgridcolumnname API returns the value column1.

Regards,
Ibrahim

link

answered 24 Dec '13, 06:42

Ibrahim%20Sandalli's gravatar image

Ibrahim Sand... ♦♦
1.5k5
accept rate: 25%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×85
×30
×16

Asked: 19 Dec '13, 05:44

Seen: 1,248 times

Last updated: 24 Dec '13, 06:42


© Copyright Gerger 2017