Skip to Content
avatar image
Former Member

get selected rows using checked-box in sap.ui.table

hi experts,

i'm unable to figure out the best way to get all the selected rows using checked boxes. and use them to call a odata create service.

i'm thinking of like this:

1. create an empty js var > onselect of check box > push the selected row (with all column values) into js var

2. wn use click on submit button, use submitbatch function to push all the data into service.

is this proper way of doing? or any better way to get the selected values using api and use them to submit batch?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Best Answer
    avatar image
    Former Member
    Dec 24, 2014 at 01:43 PM

    Not sure i understood correctly. If you are thinking to initialize certain values or variables, no need to call the init() method. Instead you can have a function globally and call it in init() and in your checkbox action, which resets the required thing.

    If you still want to reload, may be you can try window.location.reload();


    Meganadhan S

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Dennis Seah

      hi Dennis,

      as said, your earlier jsbin approach was near to my requirement.. i've made it finally.. ya with lots of code changes and logic. and thanks for the changed jsbin .. which takes the array.. thanks again.

      so what i'm doing is forming a required key during onCheck and using it to get the row-data by passing it onto oModel.getProperty()...and processing it further..!