I want to add a Table to Transparent container in Web dynpro component. An error occurred when I run the pgm.
My source as below:
Data: lo_api type ref to if_wd_view_controller,
lo_view type ref to if_wd_view,
lr_tc type ref to cl_wd_transparent_container,
lr_table type ref to cl_wd_table.
lo_api = wd_this->wd_api( ).
lo_view ?= lo_api. " Program dummp here
cl_wd_grid_data =>new_grid_data( element = lr_data ).
lr_tc ?= wd_this->lo_view->get_element( id = 'TC2' ).
lr_tc->add_child( lr_table ).
Error message in ST22 as below:
Runtime errors: MOVE_CAST_ERROR.
Exception: CX_SY_MOVE_CAST_ERROR
The reason for the exception is: the current of the source variable does not fit into the target variable.
source type:"\FUNCTION-POOL=WDR_RG_PROXY_FACTORY\CLASS=LCL_VIEW_CTLR_PROXY"
target type:"\INTERFACE=IF_WD_VIEW"
Please suggest me how to resolve this error,thanks!
Request clarification before answering.
Hi Samuel,
do you implement the method wddomodifyview? Here you have already the parameter view.
you can reference the view with
view->get_element( ...)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 5 | |
| 4 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.