on 07-03-2012 1:19 PM
Hi all
I'm always amazed that people give 90% of the solution -- but why don't they finish it off
for example
This post would appear to solve the problem 100:
BUT WHAT IS THE DATA DEFINITION FOR VIEW -- that's 99.999999% of the problem -- then it's easy but he's left the actual core of the problem out
here's his code
.............................................
I create a attribute to hold your view object. GO_view type ref to if_wd_view.
in the WDDOMODIFYVIEW method get the reference of your view.
if firsttime. go_view = view ====> PLEASE DATA DEFINITION here for VIEW
. endif.
Now write a method to add tab to exisiting tab strip.
data: lo_tab_strip type ref to CL_WD_TABSTRIP. lo_tab
type ref to cl_wd_tab.
lo_tab_strip ?= go_view->get_element( id = *'fill in the id of the tabstrip'* )
. if lo_tab_strip is bound. " use static method to create a tab,use importing parameters like ID.
lo_tab = cl_wd_tab=>new_tab( ) .
lo_tab_strip->add_tab( the_tab = lo_tab
) endif.
Without that this can't possibly work.
I tried to assume the VIEW was type string but then I get type view cannot be converted into the type go_view.
I'm C'mon guy (Baskaran Senthival in his post dEC 03 2010 if you comment "Fill in name of tabstrip" which IS obvious why not comment the other bit
I'm sure it's easy but I've missed this one somewhere
cheers
jimbo
Hi James,
The original poster gave two clues as to the data definition of the variable, VIEW. The first clue is you are in method WDDOMODIFYVIEW. If you look at the signature of that method, VIEW is an importing argument of type IF_WD_VIEW. The second clue is the assignment GO_VIEW = VIEW. Since we know GO_VIEW is defined to be of type IF_WD_VIEW, VIEW must also be the same data type.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.