How to display an OO ALV in a Popup?
The ALV will be non-editable but it has to be able to have the hotspot functionality, so it has to be done in OO. Is there any function module that will display my OO alv as a popup?
* Show as popup
CALL METHOD gr_grid->set_screen_popup( EXPORTING start_column = 10
end_column = 130
start_line = 5
end_line = 15 ).
* Define a column as hotspot
DATA:
lr_columns TYPE REF TO cl_salv_columns_table,
lr_column TYPE REF TO cl_salv_column,
lr_cols TYPE REF TO cl_salv_columns,
lr_column_list TYPE REF TO cl_salv_column_list.
lr_cols = lr_columns.
lr_columns = gr_grid->get_columns( ).
lr_column_list ?= lr_cols->get_column( 'MYCOLUMN' ).
lr_column_list->set_cell_type( if_salv_c_cell_type=>hotspot ).
Similar Messages
-
How to display total in ALV Header
How to display total in ALV Header?
Hi Venkey,
As far as your issue is concerned I would like to quote my perception.
Create a header internal table with title and number of records.
At the later part of your program you should have found the total number of records ,now assign it to the header internal table and print it.
For further clarification you can go check this link:
http://wiki.sdn.sap.com/wiki/display/ABAP/AddHeadertoALVreport
Thanks
P.Srikanth -
How to display LOGO in ALV grid when using class CL_GUI_ALV_GRID
Hello everyone,
please let me know how to display Company logo as the header part in the report program with the class cl_gui_alv_grid.
Thanks and regards,
Padma.Hi,
Got this info from a site.
http://sap.ittoolbox.com/documents/document.asp?i=3213
In the transaction OAOR, you should be able to insert your company Logo.
GOTO - OAOR (Business Document Navigator)
Give Class Name - PICTURES Class Type - OT..... then Execute
It will show you the list, then select ENJOYSAP_LOGO.
On that list, you will find one control with a "create" tab.
Click std. doc types.
Select SCREEN and double-click.
It will push FILE selection screen.
Select your company logo (.gif) and press OK.
It will ask for a description- for instance: "company logo".
It will let you know your doc has been stored successfully.
You can find your logo under ENJOYSAP_LOGO->Screen->company logo.
Just run your ALV program, you should find your company logo in place of the EnjoySAP logo.
Try this one.
Also have a look at this link
http://www.sap-img.com/fu002.htm
Message was edited by: Judith Jessie Selvi -
How to display icon in alv report output
hi,
my ewquirement in in alv report in one column to diaplay the icon(tickmark) based on some codition.
how to achieve it??
condition is
Affected (Locked on Current ECM) u2013 can use symbols for affected and for changing u2013
u2022 Lock AEOI u2013 CCLCK for AE01-OBJKT (Material) lock.
Condition:
If AEOI u2013 CCLCK is activated then display symbols (tickmark) in line of their AE01-OBJKT (Material). else display
(x mark)Hi,
In field catalog of grid set
Ex--
when 'Field'.
lwa_fcat-icon = c_true.
based on your condition
set the desired icon in table.
Ex.... lwa_table-field = icon_tick. -
How to Display Logo in ALV Header?
Hi
I want to display/ print my company logo image in ALV Header. Please help me how can I do this?
Thanks
Iftikhar Ali
Islamabad.Hi,
If you are already having a logo say ZLOGO .
You can use it this way .
Give TOP-OF-PAGE
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = gd_repid
i_callback_top_of_page = 'TOP-OF-PAGE' "see FORM
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
i_save = 'X'
tables
t_outtab = it_ekko
exceptions
program_error = 1
others = 2.
And in top of page do this .
FORM top-of-page.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRIT
EXPORTING
IT_LIST_COMMENTARY = IT_LISTHE
i_logo = 'ZLOGO'
I_END_OF_LIST_GRID =
endform.
Hope this will work .
Reward if found useful.
Regards
SureshP. -
Hi,
Can anyone tell how I will get the following output in ALV grid?
some records (or items) are starts from second column onwards and some from third colum onwards ...
thanks in advance.Hi Munvar,
When you display the ALV you need to pass the values in the form of internal table. now its upto you to decide the field catalog of the ALV grid and you can insert your own logic to display the ALV grid where in the records can be seen in the second or third column depending upon the field position of the internal table.
To display the ALV grid here is an example.
data : itab2 type table of <table>.
x_fieldcat-fieldname = '<field1>'.
x_fieldcat-tabname = '<table>'.
x_fieldcat-col_pos = 1.
append x_fieldcat to it_fieldcat.
clear x_fieldcat.
x_fieldcat-fieldname = '<field2>'.
x_fieldcat-tabname = '<table>'.
x_fieldcat-col_pos = 2.
append x_fieldcat to it_fieldcat.
clear x_fieldcat.
select * from <table> into table itab2.
call function 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
it_fieldcat = it_fieldcat
TABLES
t_outtab = itab2
EXCEPTIONS
program_error = 1
others = 2.
if
sy-subrc = 0.
endif.
endform.
Hope this helps.
Regards,
Kinshuk -
how can we display our own images in an alv output...
hi,
first import the logo from desktop using se78.
then use the function module in alv program.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = IT_LISTHEADER
I_LOGO = 'RAJI'
I_END_OF_LIST_GRID =
I_ALV_FORM =
thanks,
raji -
How to display rsa3 with ALV grid
Hello,
In some of tyhe systems i'm working with, RSA3 have a button to display the data in ALV grid. I checked and it's not because of the support package. Cab someone please advice how to add the ALV functionality.
Thanks,
Amir
Edited by: Amir Dror on Jan 13, 2009 12:41 PMHello,
we had the same question and problem.
SAP told us via OSS the following:
"... The ALV grid in RSA3 will be supported with the PI_BASIS 2006_1_700.
But you have PI_BASIS 2005_1_700
Furthermore this software component PI_BASIS is independent from the
BW releases so that you can upgrade the latest support packages of the
PI_BASIS 2006_1_700 in source system"
So if you have PI_BASIS 2005 you won't have the functionality of ALV grid in TC RSA3.
(remark: At the moment I can not confirm that ALV grid in RSA3 is available with PI_BASIS 2006_x_xxx. We plan to upgrade in a few month.)
Best regards -
How to display data in alv through double click
Hello Friends,
I am new to this community,please tell me if I make any mistake while posting.
Friends I had written this code. ALV is displayed at first time but when I am double clicking on the row then error is coming related to mismatch of actual and formal paramaters while calling function 'USER_COMMAND'. I am unable to locate where the error is. Please help me out.
REPORT ZALV12.
TYPE-POOLS SLIS.
DATA: it_vbak type standard table of VBAK,
it_vbap type table of VBAP.
DATA: wa_vbak like line of it_vbak,
wa_vbap like line of it_vbap.
DATA syrepid like sy-repid.
DATA:fld_vbak type SLIS_T_FIELDCAT_ALV,
fld_vbap type SLIS_T_FIELDCAT_ALV.
DATA:fld_wa_vbak type SLIS_FIELDCAT_ALV,
fld_wa_vbap type SLIS_FIELDCAT_ALV.
DATA:vevent type SLIS_T_EVENT,
waevent type SLIS_ALV_EVENT.
DATA:LST_HEADR type SLIS_T_LISTHEADER.
DATA title_alv type LVC_TITLE value 'LIST FOR VBAK'.
INITIALIZATION.
syrepid = sy-repid.
perform get_event.
perform populate_event.
perform set_list_headr using LST_HEADR.
perform field_cat.
START-OF-SELECTION.
..... "code for displaying data from table VBAK in ALV.
form USER_COMMAND using R_UCOMM type SY-UCOMM. "error is in this function.
data r_selfield type SLIS_SELFIELD.
case R_UCOMM.
when '&IC1'.
read table it_vbak into wa_vbak index r_selfield-TABINDEX.
perform data_select.
perform list_heading using LST_HEADR.
perform event_get.
perform build_event.
perform alv_display.
endcase.
endform.
form data_select.
select * from VBAP into table it_vbap up to 20 rows.
endform.
form list_heading using i_lst type SLIS_T_LISTHEADER.
data HLINE type SLIS_LISTHEADER.
HLINE-TYP = 'H'.
HLINE-INFO = 'FOR VBAP'.
append HLINE to i_lst.
endform.
form alv_display.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = syrepid
I_STRUCTURE_NAME = 'VBAP'
I_GRID_TITLE = 'SCREEN2_VBAP'
TABLES
T_OUTTAB = it_vbap
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
endform.
form event_get.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
I_LIST_TYPE = 0
IMPORTING
ET_EVENTS = vevent
EXCEPTIONS
LIST_TYPE_WRONG = 1
OTHERS = 2
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
endform.
form build_event.
read table vevent into waevent with key name = 'TOP_OF_PAGE'.
if sy-subrc = 0.
waevent-form = 'F_TOP_OF_PAGE'.
modify vevent from waevent transporting form
where name = 'TOP_OF_PAGE'.
endif.
endform.
form F_TOP_OF_PAGE.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = LST_HEADR
I_LOGO =
I_END_OF_LIST_GRID =
I_ALV_FORM =
endform.You missed one paramete in user_command form
FORM user_command USING r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield.
Regards,
Raymond -
How to display subtotal in ALV, where the field is not a numeric.
Hi
We are having a requirement to display the sub total for a field using ALV grid display, where the field is not numeric.
The field is characte, Status field(consists of values Submit, Approve ,Reject), where the subtotal should be value of count of group by status .
say status with submit are 10 records, so after all records with submit status are, displyed, we need to display its subtotal as 10.
Thanks & AdvanceHi Satya,
REPORT z_alv_subtotal.*&---------------------------------------------------------------------*
*& Table declaration
*&---------------------------------------------------------------------*TABLES: ekko.*&---------------------------------------------------------------------*
*& Type pool declaration
TYPE-POOLS: slis. " Type pool for ALV*&---------------------------------------------------------------------*
*& Selection screen
SELECT-OPTIONS: s_ebeln FOR ekko-ebeln.*&---------------------------------------------------------------------*
*& Type declaration
*&---------------------------------------------------------------------** Type declaration for internal table to store EKPO data
TYPES: BEGIN OF x_data,
ebeln TYPE char30, " Document no.
ebelp TYPE ebelp, " Item no
matnr TYPE matnr, " Material no
matnr1 TYPE matnr, " Material no
werks TYPE werks_d, " Plant
werks1 TYPE werks_d, " Plant
ntgew TYPE entge, " Net weight
gewe TYPE egewe, " Unit of weight
END OF x_data.*&---------------------------------------------------------------------*
*& Internal table declaration
DATA:* Internal table to store EKPO data
i_ekpo TYPE STANDARD TABLE OF x_data INITIAL SIZE 0,
* Internal table for storing field catalog information
i_fieldcat TYPE slis_t_fieldcat_alv,
* Internal table for Top of Page info. in ALV Display
i_alv_top_of_page TYPE slis_t_listheader,
* Internal table for ALV Display events
i_events TYPE slis_t_event,
* Internal table for storing ALV sort information
i_sort TYPE slis_t_sortinfo_alv,
i_event TYPE slis_t_event.*&---------------------------------------------------------------------*
*& Work area declaration
*&---------------------------------------------------------------------*DATA:
wa_ekko TYPE x_data,
wa_layout TYPE slis_layout_alv,
wa_events TYPE slis_alv_event,
wa_sort TYPE slis_sortinfo_alv.*&---------------------------------------------------------------------*
*& Constant declaration
*&---------------------------------------------------------------------*CONSTANTS:
c_header TYPE char1
VALUE 'H', "Header in ALV
c_item TYPE char1
VALUE 'S'.*&---------------------------------------------------------------------*
*& Start-of-selection event
*&---------------------------------------------------------------------*START-OF-SELECTION.* Select data from ekpo
SELECT ebeln " Doc no
ebelp " Item
matnr " Material
matnr " Material
werks " Plant
werks " Plant
ntgew " Quantity
gewei " Unit
FROM ekpo
INTO TABLE i_ekpo
WHERE ebeln IN s_ebeln
AND ntgew NE '0.00'. IF sy-subrc = 0.
SORT i_ekpo BY ebeln ebelp matnr .
ENDIF.* To build the Page header
PERFORM sub_build_header.* To prepare field catalog
PERFORM sub_field_catalog.* Perform to populate the layout structure
PERFORM sub_populate_layout.* Perform to populate the sort table.
PERFORM sub_populate_sort.* Perform to populate ALV event
PERFORM sub_get_event.END-OF-SELECTION.* Perform to display ALV report
PERFORM sub_alv_report_display.
*& Form sub_build_header
* To build the header
* No Parameter
FORM sub_build_header .* Local data declaration
DATA: l_system TYPE char10 , "System id
l_r_line TYPE slis_listheader, "Hold list header
l_date TYPE char10, "Date
l_time TYPE char10, "Time
l_success_records TYPE i, "No of success records
l_title(300) TYPE c. " Title
* Title Display
l_r_line-typ = c_header. " header
l_title = 'Test report'(001).
l_r_line-info = l_title.
APPEND l_r_line TO i_alv_top_of_page.
CLEAR l_r_line.* Run date Display
CLEAR l_date.
l_r_line-typ = c_item. " Item
WRITE: sy-datum TO l_date MM/DD/YYYY.
l_r_line-key = 'Run Date :'(002).
l_r_line-info = l_date.
APPEND l_r_line TO i_alv_top_of_page.
CLEAR: l_r_line,
l_date.ENDFORM. " sub_build_header
*& Form sub_field_catalog
* Build Field Catalog
* No Parameter
FORM sub_field_catalog .* Build Field Catalog
PERFORM sub_fill_alv_field_catalog USING: '01' '01' 'EBELN' 'I_EKPO' 'L'
'Doc No'(003) ' ' ' ' ' ' ' ', '01' '02' 'EBELP' 'I_EKPO' 'L'
'Item No'(004) 'X' 'X' ' ' ' ', '01' '03' 'MATNR' 'I_EKPO' 'L'
'Material No'(005) 'X' 'X' ' ' ' ', '01' '03' 'MATNR1' 'I_EKPO' 'L'
'Material No'(005) ' ' ' ' ' ' ' ',
'01' '04' 'WERKS' 'I_EKPO' 'L'
'Plant'(006) 'X' 'X' ' ' ' ', '01' '04' 'WERKS1' 'I_EKPO' 'L'
'Plant'(006) ' ' ' ' ' ' ' ', '01' '05' 'NTGEW' 'I_EKPO' 'R'
'Net Weight'(007) ' ' ' ' 'GEWE' 'I_EKPO'.ENDFORM. " sub_field_catalog*&---------------------------------------------------------------------*
*& Form sub_fill_alv_field_catalog
*& For building Field Catalog
*& p_rowpos Row position
*& p_colpos Col position
*& p_fldnam Fldname
*& p_tabnam Tabname
*& p_justif Justification
*& p_seltext Seltext
*& p_out no out
*& p_tech Technical field
*& p_qfield Quantity field
*& p_qtab Quantity table
FORM sub_fill_alv_field_catalog USING p_rowpos TYPE sycurow
p_colpos TYPE sycucol
p_fldnam TYPE fieldname
p_tabnam TYPE tabname
p_justif TYPE char1
p_seltext TYPE dd03p-scrtext_l
p_out TYPE char1
p_tech TYPE char1
p_qfield TYPE slis_fieldname
p_qtab TYPE slis_tabname.* Local declaration for field catalog
DATA: wa_lfl_fcat TYPE slis_fieldcat_alv. wa_lfl_fcat-row_pos = p_rowpos. "Row
wa_lfl_fcat-col_pos = p_colpos. "Column
wa_lfl_fcat-fieldname = p_fldnam. "Field Name
wa_lfl_fcat-tabname = p_tabnam. "Internal Table Name
wa_lfl_fcat-just = p_justif. "Screen Justified
wa_lfl_fcat-seltext_l = p_seltext. "Field Text
wa_lfl_fcat-no_out = p_out. "No output
wa_lfl_fcat-tech = p_tech. "Technical field
wa_lfl_fcat-qfieldname = p_qfield. "Quantity unit
wa_lfl_fcat-qtabname = p_qtab . "Quantity table IF p_fldnam = 'NTGEW'.
wa_lfl_fcat-do_sum = 'X'.
ENDIF.
APPEND wa_lfl_fcat TO i_fieldcat.
CLEAR wa_lfl_fcat.
ENDFORM. " sub_fill_alv_field_catalog*&---------------------------------------------------------------------*
*& Form sub_populate_layout
* Populate ALV layout
* No Parameter
FORM sub_populate_layout . CLEAR wa_layout.
wa_layout-colwidth_optimize = 'X'." Optimization of Col widthENDFORM. " sub_populate_layout*&---------------------------------------------------------------------*
*& Form sub_populate_sort
* Populate ALV sort table
* No Parameter
FORM sub_populate_sort .* Sort on material
wa_sort-spos = '01' .
wa_sort-fieldname = 'MATNR'.
wa_sort-tabname = 'I_EKPO'.
wa_sort-up = 'X'.
wa_sort-subtot = 'X'.
APPEND wa_sort TO i_sort .
CLEAR wa_sort.* Sort on plant
wa_sort-spos = '02'.
wa_sort-fieldname = 'WERKS'.
wa_sort-tabname = 'I_EKPO'.
wa_sort-up = 'X'.
wa_sort-subtot = 'X'.
APPEND wa_sort TO i_sort .
CLEAR wa_sort.
ENDFORM. " sub_populate_sort*&---------------------------------------------------------------------*
*& Form sub_get_event
* Get ALV grid event and pass the form name to subtotal_text
* event
* No Parameter
FORM sub_get_event .
CONSTANTS : c_formname_subtotal_text TYPE slis_formname VALUE
'SUBTOTAL_TEXT'. DATA: l_s_event TYPE slis_alv_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 4
IMPORTING
et_events = i_event
EXCEPTIONS
list_type_wrong = 0
OTHERS = 0.* Subtotal
READ TABLE i_event INTO l_s_event
WITH KEY name = slis_ev_subtotal_text.
IF sy-subrc = 0.
MOVE c_formname_subtotal_text TO l_s_event-form.
MODIFY i_event FROM l_s_event INDEX sy-tabix.
ENDIF.ENDFORM. " sub_get_event*&---------------------------------------------------------------------*
*& Form sub_alv_report_display
* For ALV Report Display
* No Parameter
FORM sub_alv_report_display .
DATA: l_repid TYPE syrepid .
l_repid = sy-repid .* This function module for displaying the ALV report
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = l_repid
i_callback_top_of_page = 'SUB_ALV_TOP_OF_PAGE'
is_layout = wa_layout
it_fieldcat = i_fieldcat
it_sort = i_sort
it_events = i_event
i_default = 'X'
i_save = 'A'
TABLES
t_outtab = i_ekpo
EXCEPTIONS
program_error = 1
OTHERS = 2.
IF sy-subrc <> 0.
* MESSAGE i000 WITH 'Error in ALV report display'(055).
ENDIF.ENDFORM. " sub_alv_report_display*&---------------------------------------------------------------------*
* FORM sub_alv_top_of_page
* Call ALV top of page
* No parameter
*---------------------------------------------------------------------*FORM sub_alv_top_of_page. "#EC CALLED* To write header for the ALV
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = i_alv_top_of_page.
ENDFORM. "alv_top_of_page*&---------------------------------------------------------------------*
*& Form subtotal_text
* Build subtotal text
* P_total Total
* p_subtot_text Subtotal text info
FORM subtotal_text CHANGING
p_total TYPE any
p_subtot_text TYPE slis_subtot_text.
* Material level sub total
IF p_subtot_text-criteria = 'MATNR'.
p_subtot_text-display_text_for_subtotal
= 'Material level total'(009).
ENDIF.* Plant level sub total
IF p_subtot_text-criteria = 'WERKS'.
p_subtot_text-display_text_for_subtotal = 'Plant level total'(010).
ENDIF.
ENDFORM. "subtotal_text
Regards,
Pravin -
How to display logo in alv grid display
Hi, i am using 'REUSE_ALV_COMMENTARY_WRITE' to display logo. but i couldn't get in the output.
plain explain how use this functoin module.
DATA : it_listheader TYPE slis_t_listheader.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = it_listheader
i_logo = 'LOGO'.hi
i am doing month wise customer sale report.
the output should like that
month customer1 customer2 customer3 customer 4 total
jan 100 200 200 - 500
feb 300 300
mar
apr
total 100 200 500 800
i want to do this dynamicaly.
let me know how can i display customer as a header. -
How to display tooltip in ALV GRID CELL?
Hello,
I'm trying to display dynamic tootips for data in ALV GRID Cells.
My ALV Gid Cells content does not display Icon or symbol or Exception but pure data (In my case dates).
Is there a way to do display a toolip that will change dynamicaly according to a rule.
I took a look at the BCALV_DEMO_TOOLTIP program
but it does not answer my expectation since it display
toltip for Icon or symbol or Exception.
Can someone help on this case.
Best regards
HarryHai Harry
icon
value set: SPACE, 'X' 'X' = column contents to be output as an icon.
The caller must consider the printability of icons.
symbol
value set: SPACE, 'X' 'X' = column contents are to be output as a symbol.
The internal output table column must be a valid symbol character.
The caller must consider the printability of symbols.
Symbols can usually be printed, but may not always be output correctly, depending on the printer configuration.
Thanks & regards
Sreenu -
How to display image on alv display screen
Hi All,
I am using "REUSE_ALV_GRID_DISPLAY" function module for display a simple report.
I want to add a logo also on that output screen. Can anyone tell me how i can do that?
Thanks and Regards,
Nidhi Srivastava.Yes.
But you have to paint the image after the native component has painted the text, to avoid the native component from erasing your image. Something like this should work.
class MyTextField extends TextField implements Runnable
public void paint(Graphics g)
super.paint(g);
new Thread(this).start();
public void run()
Thread.yield();
Graphics g = getGraphics();
g.drawImage(....) -
How to display total in alv only for single row
Hello,
I wish to replace VAT field in my ALV OUTPUT from another ITAB using READ TABLE. But in ALV output I have multiple rows for one document number.
So the value is assigning to all the rows in output, is it possible to assign that VAT value to only one row ( to any one record from output with corresponding document number) .
Thanks in advance.
Regards,
Ritesh InamdarHi Sudeesh,
I am fetching data for PO details, GR details along with condition types of PO.
All data is collected in ALV OUTPUT itab, after this I am trying to assign the values of VAT from another itab in ALV OUTPUT LOOP using READ TABLE with reference to PO-PO_ITEM-CONDITION_TYPE.
Now, when the alv loop is getting executed and in that I am fetching data for VAT using READ statement, the program is assigning VAT to all records of output alv with comparison of PO-PO_ITEM-CONDITION_TYPE.
see:
LOOP AT it_alv ASSIGNING <fs-alv>.
READ TABLE it_vat ASSIGNING <fs-vat>
WITH KEY ebeln = <fs-alv>-ebeln
posnr = <fs-alv>-posnr
kschl = 'JVCS'.
IF sy-subrc = 0.
<fs-alv>-vat = <fs-vat>-kbetr / 10.
<fs-alv>-vat_val = <<fs-alv>-vat * it_alv-menge.
END IF.
END LOOP.
Please refer above.
Thanks.
Ritesh -
How to display standard ALV toolbar function in Webdynpro ABAP
Hi All,
Could any one please let me know that how to display the standard ALV functions. What I tried is as follows:
data :lr_config_table type ref to cl_salv_wd_config_table.
data lr_function type ref to cl_salv_wd_function_std
Got the reference by calling the get_model().
Now tried to display a standard button say :
CALL METHOD lr_config_table ->if_salv_wd_function_settings~get_function_std
EXPORTING
id = 'SALV_WD_INPUT_INSERT_ROW'
RECEIVING
value = lr_function.
CALL METHOD lr_function->set_visible
EXPORTING
value = cl_wd_uielement=>e_visible-visible.
But I can't see the button added to my ALV toolbar! Could any one please help me out on this if I am missing something.
Many Thanks!
SomnathHi..
ALV report which when displayed normally allows users to insert and delete rows using the methods below from class Cl_Salv_Wd_Config_Table:
I think add these lines to your code and check..
IF_SALV_WD_TABLE_SETTINGS~SET_READ_ONLY (false)
IF_SALV_WD_STD_FUNCTIONS~SET_EDIT_INSERT_ROW_ALLOWED (true).
DATA: l_ref_cmp_usage TYPE REF TO if_wd_component_usage.
l_ref_cmp_usage = wd_this->wd_cpuse_alv_basic( ).
IF l_ref_cmp_usage->has_active_component( ) IS INITIAL.
l_ref_cmp_usage->create_component( ).
ENDIF.
DATA l_salv_wd_table TYPE REF TO iwci_salv_wd_table.
l_salv_wd_table = wd_this->wd_cpifc_alv_basic( ).
DATA l_table TYPE REF TO cl_salv_wd_config_table.
l_table = l_salv_wd_table->get_model( ).
l_table->if_salv_wd_table_settings~set_read_only( abap_false ).
l_table->if_salv_wd_std_functions~set_edit_append_row_allowed( abap_false ).
l_table->if_salv_wd_std_functions~set_edit_insert_row_allowed( abap_false ).
l_table->if_salv_wd_std_functions~set_edit_delete_row_allowed( abap_false ).
Cheers,
Kris.
Maybe you are looking for
-
Macbook Pro (Retina mid 2012) going to sleep on its own
Did some web searches here and elsewhere and saw no list of affected users. This wasn't happening before Yosemite, and pretty sure it was happening before latest update (10.10.1). I'll be using my MBP (2.3Ghz i7, 16GB RAM, 256GB SSD) and the screen w
-
how do you use game center on multiple ipods with same apple id but different usernames?
-
Linking to new page from BLOB image in report
Hi Guys, I have added an image to my report using the number/Date format field IMAGE:CITIES:CTY_PHOTO:CTY_NR::::::inline:Download. This works great! :) I know want the user to click on the image and go to the next page, setting the city code that was
-
Unlocked previous documents are blank
cannot open any recent unlocked docs, pages are blank as if hidden.
-
After a Time Machine restore of my main drive it is back in business except for Mail (5.3). I think that is the only item. It starts like normal but sits for ever and have to force quit. I have booted from a different backed up drive (carbon copy 2