cancel
Showing results for 
Search instead for 
Did you mean: 

Table view Event handling

Former Member
0 Kudos

Hi Experts,

Im using MVC. I get the data's from MBEW and displays in to one Table view. My table view displays the data's like,

-


MATNO DESCRIPTION QUANTITY PRICE

M-10 PENCIL 1 10.00

-


The Quantity field is in Edit mode. Now user change the Quantity from 1 to 5. So,

-


MATNO DESCRIPTION QUANTITY PRICE

M-10 PENCIL 5 10.00

-


I want to catch these changed Table view data's in to my Internal Table. Please

Any body give me the idea.

Thanks,

Points Assured.

View Entire Topic
StefanRoesch
Active Participant
0 Kudos

Hello Jasmin,

when you use MVC it's easy to use data-binding (model-Bindung). When you already use a model you just need to keep your internal Table as attribute in your model. Now just modify the table-parameter of your htmlb:tableView tag within your View to something like this:

table           = "//model/mytable"

the //-syntax indicates the data-binding.

....so with the following server event after a field is changed the value is also updated in your model.

hope this helps...

stefan.

Former Member
0 Kudos

Hi Stefan,

In table view doesn't have a attribute like table. So It shows the Syntax error.

Actually I need the changed cell value(5) from that table view. So please give me the sample code.

Thanks.

Former Member
0 Kudos

use this HTMLB Tag

<htmlb:tableView id              = "ID"
                 table           = "//model/gt_vac"
                 filter          = "SERVER"
                 keyColumn       = "MATNR"
                 sort            = "SERVER"
                 selectionMode   = "SINGLESELECT"
                 visibleRowCount = "20"/>

Hope this helps.

donot forget to include extension names on top of the view.

<%@page language="abap" %>
<%@extension name="htmlb" prefix="htmlb" %>
<%@extension name="phtmlb" prefix="phtmlb" %>

Amandeep