on 11-05-2013 12:01 PM
I have a column STATUS and the values of that columns are new, in progress, due to day, overdue, completed and cancelled, I want to display this rows as column headers in a table , could any one please let me know how to do this
Advance Thanks
Vijaya
New | In Progress | Due today | Completed | Overdue | Cancelled |
---|---|---|---|---|---|
5 | 5 | 1 | 2 | 3 | 4 |
Hi Vijaya,
You'll need to define a context node having this structure and a Table UI element whose data source is bound to the context node. You can use the Table Wizard to create the Table. Loop through the initial data table to build a row of status data and bind this row to the context node. For example...
LOOP AT data_table ASSIGNING <data>.
CASE <data>-status.
WHEN 'NEW'.
ADD 1 TO ls_status_data-new.
WHEN 'IN PROGRESS'.
ADD 1 TO ls_status_data-in_progress.
WHEN 'DUE'.
ADD 1 TO ls_status_data-due.
...etc...
ENDCASE.
ENDLOOP.
* Fetch the context node bound to the Table UI element
lo_nd_status_table = wd_context->get_child_node(
name = wd_this->wdctx_status_table
).
* Bind the status data
lo_nd_status_table->bind_structure(
new_item = ls_status_data
).
Cheers,
Amy
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.