Skip to Content
author's profile photo Former Member
Former Member

tableView MULTISELECT reading first record in tableview

OK, I know we've talked about this already, however I am having either a "dumb moment" or something is not right.

I do the following

data: srit TYPE INT4_TABLE.
data: table_event TYPE REF TO cl_htmlb_event_tableview.

table_event = table->data.
srit = table_event->PREVSELECTEDROWINDEXTABLE.
read table srit with key table_line = table_event->ROW_INDEX
TRANSPORTING NO FIELDS.

However it only shows the values for every line after the first record, I never get the first record from the table??? Anyone else have this problem?

I have 5 records in the table and even when I select all 5 I only have 4 in the srit table

Add comment
10|10000 characters needed characters exceeded

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Aug 03, 2004 at 09:43 AM
            field-symbols <i> type i.
            append initial line to srit assigning <i>.
            <i> = table_event->ROW_INDEX.
    

    Add that after

    read table srit with key table_line = table_event->ROW_INDEXTRANSPORTING NO FIELDS.
    

    And it takes care of the missing element.

    Add comment
    10|10000 characters needed characters exceeded

  • Posted on Aug 03, 2004 at 12:27 PM

    Hi Craig,

    Try the following:

    srit = table_event->GET_ROWS_SELECTED( includeCurrentSelectedRow = 'X' ).
    

    Best wishes,

    Steffen

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Brian McKellar

      Thanks Brian, that helps with some code reduction.

      We redesigned the BSP "alertinbox" (ok a copy of that one) to use a tableView and Multi select to "confirm" alerts.