How to add the dril down functionality in alv report.
Hi All,
I have a ALV report and now i want to add drill down functionality in this ALV report.
See my code below:
FORM f0002_build_field_catalog.
Build the field catalog
CLEAR ws_layout.
ws_layout-colwidth_optimize = 'X'.
ws_layout-edit = ' '.
ws_field_catalog-col_pos = '1'.
ws_field_catalog-fieldname = 'BUKRS'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Company Code'.
ws_field_catalog-seltext_m = 'CCode'.
ws_field_catalog-seltext_s = 'CCode'.
ws_field_catalog-fix_column = 'X'.
ws_field_catalog = 'X'.
ws_fieldcat-ref_tabname = 'VBKPF'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '2'.
ws_field_catalog-fieldname = 'BELNR'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Document no.'.
ws_field_catalog-hotspot = 'V'.
ws_field_catalog-seltext_m = 'Doc.no.'.
ws_field_catalog-seltext_s = 'Doc.no.'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '3'.
ws_field_catalog-fieldname = 'GJAHR'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Year'.
ws_field_catalog-seltext_m = 'Year'.
ws_field_catalog-seltext_s = 'Year'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '4'.
ws_field_catalog-fieldname = 'BSTAT'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Status'.
ws_field_catalog-seltext_m = 'Status'.
ws_field_catalog-seltext_s = 'Status'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '5'.
ws_field_catalog-fieldname = 'FLAG'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Open/Cleared'.
ws_field_catalog-seltext_m = 'Open/Cleared'.
ws_field_catalog-seltext_s = 'Open/Cleared'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '6'.
ws_field_catalog-fieldname = 'BLART'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Doc.Type.'.
ws_field_catalog-seltext_m = 'Doc.Type'.
ws_field_catalog-seltext_s = 'Doc.Type'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '7'.
ws_field_catalog-fieldname = 'WRBTR'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Total Amount'.
ws_field_catalog-seltext_m = 'Total Amount'.
ws_field_catalog-seltext_s = 'Total Amount'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '8'.
ws_field_catalog-fieldname = 'WAERS'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Currency.'.
ws_field_catalog-seltext_m = 'Currency'.
ws_field_catalog-seltext_s = 'Currency'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '9'.
ws_field_catalog-fieldname = 'LIFNR'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Vendor'.
ws_field_catalog-seltext_m = 'Vendor'.
ws_field_catalog-seltext_s = 'Vendor'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '10'.
ws_field_catalog-fieldname = 'NAME1'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Vendor Name'.
ws_field_catalog-seltext_m = 'Name 1'.
ws_field_catalog-seltext_s = 'Name 1'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '11'.
ws_field_catalog-fieldname = 'UZAWE'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Payment Method Supplement'.
ws_field_catalog-seltext_m = 'PmtMthSuppl'.
ws_field_catalog-seltext_s = 'PmtMthSuppl'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
ws_field_catalog-col_pos = '12'.
ws_field_catalog-fieldname = 'XBLNR'.
ws_field_catalog-tabname = 'I_OUTPUT'.
ws_field_catalog-seltext_l = 'Reference'.
ws_field_catalog-seltext_m = 'Ref. No.'.
ws_field_catalog-seltext_s = 'Ref. No.'.
APPEND ws_field_catalog TO lt_fieldcat.
CLEAR: ws_field_catalog.
g_variant-report = sy-repid.
CLEAR struct_extab.
MOVE '&XPA' TO struct_extab-fcode.
APPEND struct_extab TO i_extab.
MOVE '&OMP' TO struct_extab-fcode.
APPEND struct_extab TO i_extab.
Display the list
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = ws_repid
i_callback_user_command = 'HANDLE_USER_COMMAND'
is_layout = ws_layout
it_fieldcat = lt_fieldcat[]
it_excluding = i_extab[]
i_default = 'X'
i_save = 'U' "For user variants
is_variant = g_variant
TABLES
t_outtab = i_output.
ENDFORM. "f0002_build_field_catalog
*& Form f0038_pf_status
text
-->I_EXTAB text
FORM f0038_pf_status USING i_extab TYPE slis_t_extab. "#EC CALLED
CLEAR struct_extab.
MOVE '&XPA' TO struct_extab-fcode.
APPEND struct_extab TO i_extab.
MOVE '&OMP' TO struct_extab-fcode.
APPEND struct_extab TO i_extab.
SET PF-STATUS 'Z_PFSTATUS2' EXCLUDING i_extab.
ENDFORM. "f0038_pf_status
Pls tell me how i use this below dril down ability functionality in my code.
See the requirement below.
The Document Number, aka Accounting Document Number (BELNR) of each row will take the user to the appropriate document to edit as follows:
For Parked documents:-
If VBKPF-AWTYP (Reference Procedure) = RMRP, then the drilldown functionality should be to MIR4 using the Object ID in VBKPF- AWKEY. In this scenario the Object ID represents a Invoice Document Number, not an Accounting Document Number. Not the Object ID is a combination of Invoice Document Number and Fiscal Year
If VBKPF-AWTYP = Any other value, then the drilldown functionality should be to FBV2 using the Object ID in VBKPF-AWKEY. In this scenario the Object ID represents a true Accounting Document Number. Note the Object ID is a combination of Company Code (VBKPF-BUKRS), Accounting Document Number (VBKPF-BELNR) and Fiscal Year (VBKPF-GJAHR)
For Posted, not Cleared documents:-
Drilldown ability should be to FB02. The combination of Company Code (BSIK-BUKRS), Accounting Document Number (BSIK-BELNR) and Fiscal Year (BSIK-GJAHR) will be used to open/drilldown to the correct document in FB02.
For Cleared documents:-
Drilldown ability should be to FB03. The combination of Company Code (BSIK-BUKRS), Accounting Document Number (BSIK-BELNR) and Fiscal Year (BSIK-GJAHR) will be used to open/drilldown to the correct document in FB03.
Its very urgent, pls help on this.
Thanks!
Vipin
Pls refer :
https://wiki.sdn.sap.com/wiki/display/Snippets/ABAPInteractiveALVwithCallTransaction%28usingParameterID%29
https://wiki.sdn.sap.com/wiki/display/Snippets/ABAPInteractiveALV+Program
Regards,
Anish Thomas
Pls reward all useful answers
Similar Messages
-
How to add the REFRESH button in OOPs ALV grid
how to add the REFRESH button in OOPs ALV grid
Hi Naidu.
Check the below code:
Local Class Definition and implementation For events handeling
CLASS LCL_EVENT DEFINITION .
PUBLIC SECTION.
METHODS :TOOLBAR FOR EVENT TOOLBAR OF CL_GUI_ALV_GRID
IMPORTING E_OBJECT,
USER_COMMAND FOR EVENT USER_COMMAND OF CL_GUI_ALV_GRID
IMPORTING E_UCOMM.
ENDCLASS.
CLASS LCL_EVENT IMPLEMENTATION.
METHOD TOOLBAR.
WA_TOOL-FUNCTION = 'ZFC1'.
WA_TOOL-TEXT = 'TEST'.
WA_TOOL-ICON = '@EA@'.
APPEND WA_TOOL TO E_OBJECT->MT_TOOLBAR.
ENDMETHOD. "DISPLAY
METHOD USER_COMMAND.
IF E_UCOMM = 'ZFC1'.
ENDIF.
ENDMETHOD. "USER_COMMAND
ENDCLASS. "LCL_EVENT IMPLEMENTATION
MODULE STATUS_0200 OUTPUT.
SET PF-STATUS 'ZALV_BTON'.
SELECT * FROM VBAK INTO TABLE GT_VBAK
UP TO 30 ROWS.
**** CREATE CONTAINER OBJECT
CREATE OBJECT MY_CONTAINER
EXPORTING
CONTAINER_NAME = 'CC1'
EXCEPTIONS
CNTL_ERROR = 1
CNTL_SYSTEM_ERROR = 2
CREATE_ERROR = 3
LIFETIME_ERROR = 4
LIFETIME_DYNPRO_DYNPRO_LINK = 5
OTHERS = 6 .
****** GRID TO CONTAINER
CREATE OBJECT ALV
EXPORTING
I_PARENT = MY_CONTAINER
EXCEPTIONS
ERROR_CNTL_CREATE = 1
ERROR_CNTL_INIT = 2
ERROR_CNTL_LINK = 3
ERROR_DP_CREATE = 4
OTHERS = 5.
CREATE OBJECT OBJ.
SET HANDLER : OBJ->TOOLBAR FOR ALV.
SET HANDLER : OBJ->USER_COMMAND FOR ALV.
****** ALV DISPLAY
CALL METHOD ALV->SET_TABLE_FOR_FIRST_DISPLAY
EXPORTING
I_STRUCTURE_NAME = 'VBAK'
CHANGING
IT_OUTTAB = GT_VBAK[]
EXCEPTIONS
INVALID_PARAMETER_COMBINATION = 1
PROGRAM_ERROR = 2
TOO_MANY_LINES = 3
OTHERS = 4.
ENDMODULE. " STATUS_0200 OUTPUT
*& Module USER_COMMAND_0200 INPUT
* text
MODULE USER_COMMAND_0200 INPUT.
IF SY-UCOMM EQ 'BACK'.
LEAVE PROGRAM.
ENDIF.
ENDMODULE. " USER_COMMAND_0200 INPUT
Regards
Kumar M -
How to Change the position of Column in ALV report
Hi Follks,
Is is possible to change the position of column in ALV report?.If yes then how?
Basically my requirement is, that user want afacility where , he should be able to change the position
of column aftre he runs the report.
Eg: After running the report , user felt that column 5 should be at position 2 , in that case he should
be able to drag column 5 at position 2 and vice versa.
Please help me, how to solve this issue.
Note : I am using NW 7.0 SP 9
Regards
PG
Edited by: PG on Apr 13, 2009 11:10 AMHI PG,
do below whie filling the filed catlog
wa_fieldcat-fieldname = 'Field1".
wa_fieldcat-COL_POS = '1',
append wa_fieldcat to it_fieldcat.
wa_fieldcat-fieldname = 'Field2".
wa_fieldcat-COL_POS = '2',
wa_fieldcat-fieldname = 'Field3".
wa_fieldcat-COL_POS = '3',
Thanks! -
How can give the user defined parameter in alv report
Hi experts
I have created one alv report for Sale Order statement.In this alv report have different input parameters
My problem is in this alv i have two input field Sales Orgaization and Plant.When I set this parameter value in user details it snot affected in my alv report.But it is affected in the standard alv report.How can
i rectify this
Regards
Manojhi
i think don't use set parameter value, use there SUBMIT & RETURN statement and write in USER_COMMAND function.
FORM USER_COMMAND USING P_UCOMM LIKE SY-UCOMM
P_SELFIELD TYPE SLIS_SELFIELD.
SUBMIT program name AND RETURN
WITH <selection-screen field> IN <selection-screen field>
WITH WERKS IN WERKS .
ENDFORM .
Regards,
Abhi -
How to read the check box value in alv report
hi experts,
i m working on one alv report where i m using the check box for field selection in alv display.
but i don't know how to read the only selected fields.
wa_fieldcat-fieldname = 'BOX'.
wa_fieldcat-tabname = 'IT_HEADER'.
wa_fieldcat-seltext_m = 'Box'.
wa_fieldcat-checkbox = 'X'.
wa_fieldcat-input = 'X'.
wa_fieldcat-edit = 'X'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
wa_fieldcat-fieldname = 'AUFNR'.
wa_fieldcat-tabname = 'IT_HEADER'.
wa_fieldcat-seltext_m = 'Sales Doc'.
wa_fieldcat-hotspot = 'X'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = v_repid
I_CALLBACK_PF_STATUS_SET = 'SET_PF_STATUS'
i_callback_user_command = 'USER_COMMAND'
i_callback_top_of_page = 'TOP_OF_PAGE'
it_fieldcat = i_fieldcat[]
i_save = 'A'
it_events = v_events
TABLES
t_outtab = it_header
EXCEPTIONS
PROGRAM_ERROR = 1
OTHERS = 2
*& Form USER_COMMAND
text
-->R_UCOMM text
-->, text
-->RS_SLEFIELDtext
FORM user_command USING r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield.
CASE r_ucomm.
when '&RELEAS'.
endcase
endform.
i gone through some already posted que for same problem i tried options like
loop at it_header.
endloop.
but i m getting box field empty.
is there i missed something? plz sugeest.. if u have any other solution plz post...Have this code in your user command fm:
* For capturing changed data
CALL FUNCTION 'GET_GLOBALS_FROM_SLVC_FULLSCR'
IMPORTING
e_grid = w_grid.
CALL METHOD w_grid->check_changed_data
IMPORTING
e_valid = w_valid.
IF w_valid = 'X'.
loop at itab where mark = 'X'.
endloop.
ENDIF.
Regards,
Ravi -
How to print the logo in top centre (alv report)
Hi friends,
I need to print the company logo in the centre top of the alv report.Using the reuse_alv_commentry_write the logo is coming in the right side corner of report.
Thanks & Regards,
vijay.Hi,
Try this out
Build report title
PERFORM build_report_title USING gd_report_title gd_logo.
DATA: gd_logo TYPE sdydo_value,
*& Form BUILD_REPORT_TITLE
Build table for ALVtree header
<-> p1 Header details
<-> p2 Logo value
FORM build_report_title CHANGING
pt_report_title TYPE slis_t_listheader
pa_logo TYPE sdydo_value.
DATA: ls_line TYPE slis_listheader,
ld_date(10) TYPE c.
List Heading Line(TYPE H)
CLEAR ls_line.
ls_line-typ = 'H'.
ls_line-key "Not Used For This Type(H)
ls_line-info = 'User Message Service'.
APPEND ls_line TO pt_report_title.
Users name (Status Line- TYPE S)
ls_line-typ = 'S'.
ls_line-key = 'Name '.
ls_line-info = gd_myname.
APPEND ls_line TO pt_report_title.
Status Line(TYPE S)
ld_date(2) = sy-datum+6(2).
ld_date+2(1) = '/'.
ld_date3(2) = sy-datum4(2).
ld_date+5(1) = '/'.
ld_date+6(4) = sy-datum(4).
ls_line-typ = 'S'.
ls_line-key = 'Date'.
ls_line-info = ld_date.
APPEND ls_line TO pt_report_title.
Action Line(TYPE A)
CLEAR ls_line.
ls_line-typ = 'A'.
CONCATENATE 'Report: ' sy-repid INTO ls_line-info SEPARATED BY space
APPEND ls_line TO pt_report_title.
ENDFORM. "build_report_title
CALL METHOD gd_userlist->set_table_for_first_display
EXPORTING
is_hierarchy_header = gd_hierarchy_header
it_list_commentary = gd_report_title
<b> i_logo = gd_logo</b>
i_background_id = 'ALV_BACKGROUND'
i_save = 'A'
is_variant = gd_variant
CHANGING
it_outtab = it_emptytab "Must be empty
it_fieldcatalog = gd_fieldcat. -
How to add the excel export function to CL_GUI_ALV_TREE
I am using CL_GUI_ALV_TREE to display an exploded BOM. My users want to be able to export the list to an excel spreadsheet in the same way that can be done using CL_GUI_ALV_GRID. Is this possible? I have spent the last hour searching the forum for the answer, and I cannot find anything that says this can be done.
If this has been asked and answered please point me in the right direction.
If you know that it can't be done, please tell me that too.
Thanks,
LarryLarry,
Add an EXPORT button and under that button use something like this:
REPORT ZR_DOWNLOAD_TO_EXCEL.
tables: vbak.
data: begin of lt_data_tab occurs 0,
vbeln like vbak-vbeln,
kunnr like vbak-kunnr,
ernam like vbak-ernam,
end of lt_data_tab.
data: l_filename type STRING.
data: outname type RLGRAP-FILENAME.
data: sname type RLGRAP-FILENAME.
data: begin of col_headers occurs 0,
text(10),
end of col_headers.
SELECTION-SCREEN BEGIN OF BLOCK ONE WITH FRAME TITLE TEXT-001.
selection-screen: skip 1.
parameters: cb_hdrs as checkbox.
SELECTION-SCREEN END OF BLOCK ONE.
start-of-selection.
select vbeln kunnr ernam up to 50 rows
from vbak into table lt_data_tab.
move 'c:\excel_demo' to outname.
if cb_hdrs = 'X'.
move 'Order #' to col_headers-text.
append col_headers.
move 'Sold-to #' to col_headers-text.
append col_headers.
move 'Created By' to col_headers-text.
append col_headers.
CALL FUNCTION 'MS_EXCEL_OLE_STANDARD_DAT'
EXPORTING
file_name = outname
data_sheet_name = sname
TABLES
data_tab = lt_data_tab
fieldnames = col_headers
EXCEPTIONS
file_not_exist = 1
filename_expected = 2
communication_error = 3
ole_object_method_error = 4
ole_object_property_error = 5
invalid_pivot_fields = 6
download_problem = 7
OTHERS = 8.
IF sy-subrc <> 0.
MESSAGE s000(zz) WITH 'Export to Excel failed.'.
ENDIF.
else.
CALL FUNCTION 'MS_EXCEL_OLE_STANDARD_DAT'
EXPORTING
file_name = outname
data_sheet_name = sname
TABLES
data_tab = lt_data_tab
fieldnames = col_headers
EXCEPTIONS
file_not_exist = 1
filename_expected = 2
communication_error = 3
ole_object_method_error = 4
ole_object_property_error = 5
invalid_pivot_fields = 6
download_problem = 7
OTHERS = 8.
IF sy-subrc <> 0.
MESSAGE s000(zz) WITH 'Export to Excel failed.'.
ENDIF.
endif.
Note the FM that forces down the internal table. -
How to add a field in a standard alv report and to display in result list
hi gurus,
i need to add field in selectio-screen.
i need to validate the field with existing fields.
i need to add this in alv grid output list dynamically.
thanks & regards,
kgn9.hi swaret,
i tried ur problem.....
nothing special as to be done to add a new field in elementary search........
just press F4 at parameters.
there are already 4 fields...
BUKRS
HBKID
BANKS
BANKL
you just add ur field.....
TEXT1
and specify Lpos and Spos as 5.
and activate...... thats all......
i tried and it worked for me........
i hope it was helpful for u. -
Drill Down functionality in ALV Report
Hi Experts,
Gud Afternoon..!!!
My Requirement: I have to display a report in ALV and if user click on vbeln the screen should go to transaction code VA43 for that particular contract.
I used the below code,
FORM user_command USING r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield.
data: w_vbeln type vbak-vbeln.
IF r_ucomm EQ '&IC1' . " Click value of hot spot
CASE rs_selfield-fieldname.
WHEN 'VBELN'.
w_vbeln = rs_selfield-value.
SET PARAMETER ID 'AUN' FIELD w_vbeln.
CALL TRANSACTION 'VA43' AND SKIP FIRST SCREEN.
ENDCASE.
ELSEIF r_ucomm EQ 'CANC'
OR r_ucomm EQ 'BACK'
OR r_ucomm EQ 'EXIT'.
LEAVE PROGRAM.
ENDIF.
ENDFORM. " user_command
I am getting error message in VA43 initial screen as "Enter the doc. no"
Plz help me in this. Thanks in Advance..!!!
Regards,
Vadhu...Hi,
Thanks Aakash Banga, Rimpa Abhishek..!!!
I got the solution with help of SDN. The Solution as follows,
FORM user_command USING r_ucomm LIKE sy-ucomm
rs_selfield TYPE slis_selfield.
DATA: w_vbeln TYPE vbak-vbeln.
IF r_ucomm EQ '&IC1' . " Click value of hot spot
CASE rs_selfield-fieldname.
WHEN 'VBELN'.
w_vbeln = rs_selfield-value.
REFRESH t_bdcdata.
CLEAR t_bdcdata.
t_bdcdata-program = 'SAPMV45A'.
t_bdcdata-dynpro = '102'.
t_bdcdata-dynbegin = 'X'.
APPEND t_bdcdata TO t_bdcdata.
CLEAR t_bdcdata.
t_bdcdata-fnam = 'BDC_CURSOR'.
t_bdcdata-fval = 'VBAK-VBELN'.
APPEND t_bdcdata TO t_bdcdata.
CLEAR t_bdcdata.
t_bdcdata-fnam = 'BDC_OKCODE'.
t_bdcdata-fval = '=SUCH'.
APPEND t_bdcdata TO t_bdcdata.
CLEAR t_bdcdata.
t_bdcdata-fnam = 'VBAK-VBELN'.
t_bdcdata-fval = w_vbeln.
APPEND t_bdcdata TO t_bdcdata.
CLEAR t_bdcdata.
t_bdcdata-program = 'SAPMV45A'.
t_bdcdata-dynpro = '4001'.
t_bdcdata-dynbegin = 'X'.
APPEND t_bdcdata TO t_bdcdata.
CALL TRANSACTION 'VA43' USING t_bdcdata MODE 'P' .
CALL TRANSACTION 'VA43' AND SKIP FIRST SCREEN.
ENDCASE.
ELSEIF r_ucomm EQ 'CANC'
OR r_ucomm EQ 'BACK'
OR r_ucomm EQ 'EXIT'.
LEAVE PROGRAM.
ENDIF.
ENDFORM. " user_command
Thanks & Regards,
Vadhu Duraisami -
How the Drill down functionality works if the source is Bex Query
Dear All,
How the Drill down functionality works if the source is Bex Query through the query browser in Dashboard 4.1
Please let me know process.
Thanks
Regards,
SaiHi sai,
Drill down can be done by two ways.
1. you need to bring all the data in one shot to the spreadsheet and then by using the components you can achieve it. Below given link explains in detailed about that.
Filtering Through Combo Box
2. you can use different set of query to pass the value from one set to another to fetch the data using the prompt. please check the below which explain them.
Difference between "When value Becomes & When value Changes"
Revert any clarification required on this.
--SumanT -
How to add the double headings in Alv Report.
Hi All,
Plz suggest me how to add the double headings in ALv Report.
RamHi,
Try out this program....
REPORT ypm_historycard_rep.
TYPE-POOLS : slis.
DATA : it_cbm TYPE STANDARD TABLE OF mara.
DATA : it_layout TYPE STANDARD TABLE OF slis_layout_alv WITH HEADER LINE,
wa_fcat TYPE slis_fieldcat_alv,
it_fcat TYPE slis_t_fieldcat_alv.
START-OF-SELECTION.
SELECT *
FROM mara
INTO CORRESPONDING FIELDS OF TABLE it_cbm
where matnr = 'D80K7'.
END-OF-SELECTION.
it_layout-zebra = 'X'.
it_layout-colwidth_optimize = 'X'.
it_layout-f2code = '&ETA'.
APPEND it_layout.
DEFINE macro4fcat.
wa_fcat-col_pos = &1.
wa_fcat-fieldname = &2.
wa_fcat-tabname = &3.
wa_fcat-seltext_l = &4.
append wa_fcat to it_fcat.
clear wa_fcat.
END-OF-DEFINITION.
macro4fcat '1' 'MATNR' 'IT_CBM' 'MATERIAL NO' .
DESCRIBE TABLE it_cbm.
IF sy-ucomm = '&F03'.
MESSAGE 'hi hello good morning "press enter button" this is quiz' TYPE 'S'.
ENDIF.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = sy-repid
i_callback_html_top_of_page = 'HTML_TOP_OF_PAGE'
is_layout = it_layout
it_fieldcat = it_fcat
i_save = 'A'
TABLES
t_outtab = it_cbm
EXCEPTIONS
program_error = 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.
*& Form html_top_of_page
* text
* -->TOP text
FORM html_top_of_page USING top TYPE REF TO cl_dd_document.
DATA: l_text(255) TYPE c.
DATA: text1(255) TYPE c.
DATA: t_header TYPE REF TO cl_dd_table_element ,
wa_header TYPE REF TO cl_dd_table_area.
CALL METHOD top->add_gap
EXPORTING
width = 10.
CALL METHOD top->add_text
EXPORTING
text = 'hello'
sap_style = 'HEADING'
CALL METHOD top->add_gap
EXPORTING
width = 20.
CALL METHOD top->add_text
EXPORTING
text = 'HOW ARE YOU'
sap_style = 'HEADING'.
CALL METHOD TOP->new_line
* EXPORTING
* repeat =
CALL METHOD top->add_gap
EXPORTING
width = 50.
CALL METHOD top->add_text
EXPORTING
text = '____________________________________________________________'
sap_style = 'HEADING'.
CALL METHOD TOP->new_line
* EXPORTING
* repeat =
CALL METHOD top->add_gap
EXPORTING
width = 90.
CALL METHOD top->add_text
EXPORTING
text = 'YOU CAN TRY LIKE THIS'
sap_style = 'HEADING'.
ENDFORM. "html_top_of_page
Regards
Debarshi -
How to add the Note board web part to a page with powershell
Hi everyone,
I've been looking around everywhere but haven't seen it explicitly mentioned.
Does anyone know how to add the Note Board web part to a Team Site page, e.g. Non-publishing site, Left Zone, First webpart in the zone in powershell?
Examples like this one http://adicodes.com/adding-web-part-to-page-with-powershell/ only talk about custom web parts uploaded from a local drive.
The example here looks good - http://spcrew.com/blogs/lists/posts/post.aspx?id=21 but is it for the Page Viewer Web Part. How would you go about getting the correct name for the note board web part and configuring it?
Many Thanks,
Ashley
function main(){
[void][System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint")
$url = "http://sp2010dev1/sites/test1"
$OpenWeb = Get-SPWeb $url
$OpenWeb
$OpenSite = Get-SPSite $url
$file = $OpenWeb.GetFile("http://sp2010dev1/sites/test1/SitePages/test1.aspx")
$WebPartManager = $file.GetLimitedWebPartManager([System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)
Add-PageViewerWebPart "http://sp2010dev1/sites/test1" "http://sp2010dev1/sites/test1/SitePages/test1.aspx" "Body" 0 "SPCrew Site" "sp2010dev"
$OpenWeb.Dispose()
function Add-PageViewerWebPart($SiteURL, $pageUrl, $webpartzone, $index, $title, $content)
$site = new-object Microsoft.SharePoint.SPSite($SiteURL)
$web=$site.OpenWeb()
$webpartmanager=$web.GetLimitedWebPartManager($pageUrl, [System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)
$webpart = new-object Microsoft.SharePoint.WebPartPages.PageViewerWebPart
$webpart.ChromeType = [System.Web.UI.WebControls.WebParts.PartChromeType]::TitleOnly;
$webpart.Title = $title
$webpart.ContentLink = "http://www.spcrew.com";
$webpartmanager.AddWebPart($webpart, $webpartzone, $index);
$web.Close()
$site.Close()
function Get-SPSite([string]$url) {
New-Object Microsoft.SharePoint.SPSite($url)
function Get-SPWeb([string]$url) {
$SPSite = Get-SPSite $url
return $SPSite.OpenWeb()
$SPSite.Dispose()Hi,
According to your post, my understanding is that you wanted to add the Note board web part to a page with PowerShell.
The name of the Note Board web part is SocialCommentWebPart.
I recommend to use the powershell code below:
$pageUrl="http://sitename/SitePages/test.aspx"
$SiteURL="http://sitename"
$site = new-object Microsoft.SharePoint.SPSite($SiteURL)
$web=$site.OpenWeb()
$webpartmanager=$web.GetLimitedWebPartManager($pageUrl, [System.Web.UI.WebControls.WebParts.PersonalizationScope]::Shared)
$webpart = new-object Microsoft.SharePoint.Portal.WebControls.SocialCommentWebPart
$webpart.title="Note Board"
$webpartmanager.AddWebPart($webpart, "MiddleZone", 0);
$web.Close()
Then the Note board web part will be added to the page.
Best Regards,
Linda Li
Linda Li
TechNet Community Support -
How to add a drop-down menu to a rollover image?
Hi,
I guess my title says it all... I was wondering how to add a drop-down menu to a rollover image? I know that there's the sprymenu, but I need to have my own rollover images.
Thanks,
KazemFrankly, ANY link can offer a drop down.
Take a look at this turorial.
That will get you your dropdown menu. So you have that.
Now, on your top menu (or any level where you want to have an image instead of text do this:
(I am copying the HTML structure in the tutorial here):
<nav>
<ul>
<li><a href="#">Home</a></li>
<li><a href="#">Tutorials</a>
<ul>
<li><a href="#">Photoshop</a></li>
<li><a href="#">Illustrator</a></li>
<li><a href="#">Web Design</a></li>
</ul>
</li>
<li><a href="#">Articles</a>
<ul>
<li><a href="#">Web Design</a></li>
<li><a href="#">User Experience</a></li>
</ul>
</li>
<li><a href="#">Inspiration</a></li>
</ul>
</nav>
Now, let's pretend you want an image instead of the word "Articles." You'll want the image to be sized appropriately, and if you look at the CSS, you'll see it's 112 pixels wide by 52 high. If your image is approximately those dimensions, you're all set.
So instead of "articles" you insert your image.
Done. -
Please tell me exactly how to remove the AVG search function
Please tell me exactly how to remove the AVG search function
''edited by a moderator for clarity''You don't need to repeat yourself dozens of time or use profanity to get help here.
(1) Disable ALL nonessential or unrecognized extensions on this tab. Not sure what it does? If in doubt, disable:
orange Firefox button (or Tools menu) > Add-ons > Extensions category
Use of the links above a disabled extension to restart Firefox if any appear.
(2) Reset your search providers to Google:
https://addons.mozilla.org/en-US/firefox/addon/searchreset/
(3) Check for a user.js file (do this before exiting Firefox, otherwise the settings in that file can undo your cleanup) as described in this article: [[How to fix preferences that won't save]].
(4) If AVG search took over your new tab page (Ctrl+t), change that as follows:
(A) In a new tab, type or paste '''about:config''' in the address bar and press Enter. Click the button promising to be careful.
(B) In the filter box, type or paste '''newtab''' and pause while the list is filtered
(C) Double-click the '''browser.newtab.url''' preference and enter the desired value for your preferred page:
''(i) Page thumbnails (default)'' => about:newtab
''(ii) Blank tab'' => about:blank
''(iii) Built-in Firefox home page'' => about:home
''(iv) Any other page'' => full URL to the page
IMPORTANT: If you have AVG software in your Windows Control Panel, you may also need to remove it there. -
In my opinion,
I think the rolling function of Muse need to add the group status function and group!
Because when the processing of many things, but the effect is the same,
but to repeat many times, it is necessary to group similar function of PS.I learned how to install the 9.1.3 upgrade by renaming my app, and that works fine. Logic is now recognized in About My Mac as a 64 bit app, which is where I started. Thanks for your help.
Now I have to figure out how to get my Novation to work through Automap in some way that I can finally get mixer functions. I'll repost the second part of this if I'm still having a headscratcher about it tomorrow.
Maybe you are looking for
-
Ssrs 2008 r2 use parameters for sorting purposes
In an ssrs 2008 r2 report, I have a report where a user wants to sort a report based upon the following parameters: 1. lastName, 2. firstName, 3. studentNumber, 4. [School Name]. The above is the default order of how the user wants to be
-
I used the transporter and ran into the BSOD with WinXP starting only in Safe Mode... after three transfer (the last one wireless through airport... awesome!), I figured out the problem and want to share it, since it seems pretty common by looking at
-
Update Rule: error during activate process
Dear Guys! I could not activate one of my update rules. When i go to transport connection to try solve the problem, found this errors: Object '0SPL_EXPHRZ' (IOBJ) of type 'InfoObject' is not available in version 'A' Object '0SPL_TARGET' (IOBJ) of typ
-
Can't install DVR surveilance cams in Time Capsule
I bought a Swann DVR8 -4000 Surveilance Cams adn I can't install the program. First of all, the software for Mac (MyDVR_Mac_v1.0.1.pkg) doesn't work. In a Windows computer, the software can't find the device, wich is plugged in by a LAN cable in the
-
IPhoto slideshows for Windows ?
Hi, I was not sure which forum to post this in so am posting here too. I have created a slideshow that will be played following a funeral service of a family member. I created it in iPhoto but found out that it is going to have to be played on a Wind