Quantcast
Channel: SCN : Discussion List - Business Server Pages (BSP)
Viewing all articles
Browse latest Browse all 237

Problem with tableview (column names)

$
0
0

Last week, our systems were down because of a maintenance. Today, when I've started testing things, one particular thing does not work:

 

In a BSP there is a tableview with some columns. The user changes the values available in some of these columns (through listboxes).

When saving the changes, the values are missing.

 

By debugging, I've seen that class CL_HTMLB_EVENT_TABLEVIEW has an attribute "AllColumnNames" with the different column names. It is supposed to be a table, with a line for each column name. Currently, it has a single line with the names separated by '/': "NAME1/NAME2/NAME3.....".

So, our code does not get properly the column names and so, the column values, and the values are lost.

 

I've continued debugging and I've seen that in IF_HTMLB_DATA~RESTORE_FROM_REQUEST, the code has been changed (by SAP), this is the current code snippet that causes the error:

  CONCATENATE id '_AllColumnNames' INTO name.

  value = request->get_form_field( name ).

  IF value CS ':'.

    SPLIT value AT '/' INTO TABLE me->allcolumnnames.

  ELSE.

    SPLIT value AT '/' INTO TABLE me->allcolumnnames.

  ENDIF.

 

In our case, the value does not contain the character ':', so it goes to the "else" part, and does not split anything, as it doesn't find the string '/'.

 

I've checked the iterator that defines the columns and they are defined as a TABLEVIEWCONTROLTAB (there is no '/' or ':' there).

I've made a dummy test by adding a final column to my table with ':' as name and then the data is not lost but it doesn't seem as a suitable option for me.

 

Why does the standard code expect to find ':' in the column names? And if it doesn't find it, why should the column names separated by '/'?

 

 

Many thanks,

Victor


Viewing all articles
Browse latest Browse all 237

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>