Default display of excel view in grid
hi friends..
is it possible to display grid in excel view as default? while excuting the program..
note:
not by an manual change in layout
hi try this
after dis playing grid report
Click button 'View' ( next to print button) on application toolbar
Select Excel in Place
This will download the same format as of Report
Isee this program
Program - SAPLSALV
Similar Messages
-
Editable data in excel view of alv grid
hi friends..
now i am displaying the data in alv grid..
my requirement is i want to display the data in excel format.. (not in seperate excel..)
i want to display the excel sheet with data within the screen itself.
for this
i tried this scenario by fallowing steps
in layout->view tab->microsoft excel..
(layout button in the application toolbar i.e pf-status)
it show excel sheet within report and data with excel sheet.
now i got data in excel sheet.
but my requirement is if i made any changes in data in excel means
i want those updated or edited data in the another internal table..
this scenario is work in the case of abap list viewer (instead of microsoft excel)
for this i use one button in the pf-status (UPDATE).
after made changes in grid data i export those modified data to abap memory and download to another internal table..
how can i get the same scenario in micosoft excelHi,
Please make sure that you have made a <b>global</b>
<b>declaration</b> for the ALV Grid control.If not try
with this
Please reward points if this explanation is useful.
Regards,
Siva -
Excel view in ALV Grid---- Urgent
Hi,
On executing sample porgram BCALV_FULLSCREEN_DEMO, we get ALV grid display. After that, on Clicking "<b>Microsoft Excel View(controlshiftF7)</b>" we are getting blanck Excel screen view instead of the field values.
I have the same scenario requirement in real time. I want the excel screen with values from ALV Grid.
Thanks in Advance.
-Mohan.Hi Mohan,
Try this:
Download Data in EXCEL from ALV list display
1) Once you have alv report displayed in the screen.
2) Click button 'View' ( next to print button) on application toolbar
3) Select Excel in Place
4) This will download the same format as of Report
I hope your ALV have all the Standard functions in Toolbar. If not copy the status from and get the function as mentioned above.
<b>Program - SAPLSALV
Status - STANDARD</b>
Reward points if this Helps.
Manish -
Leading Zeros Missing - When exporting data from ALV grid display to Excel
Hi,
Am exporting the data from ALV GRID DISPLAY to Excel sheet using standard toolbar icon 'Local file'
the leading zeros displayed in the ALV output is missing in the EXCEL sheet.
(eg) in ALV o/p - 0029.
in Excel - Only 29 is appearing.
As per the requiement i have to show the leading zeros in excel also.
Pls help on this issue.
Thanks in advance..Hi ,
Please set the property :
wa_fieldcat-lzero = 'X' .
when you are creating field catalog for display alv data .
your prob will solved .
Regards ,
Nilesh Jain -
Hi,
I'm searching anywhere on this forum for a solution but up to now I did only partial progress.
I've already seen dozens of sap notes about this problem.
When I pressed "view in Microsoft Excel" (code &VEXCEL) on an ALV grid list, a popup appeared noticing that no template was found. Looking around on this forum I managed to discover how to load these templates from local (BC_ALVEXCEL_SAP_TEMPL, BCALV_BDS_MAINTENANCE) or from client 000 (BCALV_BDS_IMPORT_SAP_TEMPLATE).
Anyway, I managed to restore the templates on the system, but excel view still doesn't work:
wheh I press the button now I only see a blank screen in place of the excel; if excel was already open (not in sap), then an excel view is actually shown, but the sheet is empty, no data in it.
Any hints?
thank youHi,
Just open Excel, then Goto Menu -> Tools -> Options -> Security Tab -> Macro Security ->Set Medium and in Trusted publisher tab select the checkbox Trust Access to Visual Basic Project Now Press Ok.
This will solve your problem.
Regards
Karthik D -
hi friends..
now i am displaying the data in alv grid..
my requirement is i want to display the data in excel format.. (not in seperate excel..)
i want to display the excel sheet with data within the screen itself.
for this
i tried this scenario by fallowing steps
in layout->view tab->microsoft excel..
(layout button in the application toolbar i.e pf-status)
it show excel sheet within report but no data with excel sheet.
how can i get the data into that excel sheet.
its very important..can you please tell meSelva,
This is security setting issue in Excel.
Open up MS Excel on your desktop...
From the Excel menu bar, choose: Tools > Macro > Security...
In the pop-up, change to the Security Level to Medium (or Low - if necessary).
And don't forget points for helpful answers!!! -
XML Publisher report default output in Excel format.
Hi,
We have defined one concurrent program whose output format is text, this concurrent program executable is PL/SQL and in this PL/SQL program we are generating XML data and displaying XML using below fnd_request.
l_conc_id := FND_REQUEST.SUBMIT_REQUEST('GMP','GMPPDROP','', '',FALSE,
p_sequence_num,chr(0),'','','','','','','','','','','',
We have also defined template for this.
Using below fnd_request we are choosing template and data is getting generated in PDF format. Now our requirement is to display the output by default in Excel format.
FND_REQUEST.SUBMIT_REQUEST('XDO','XDOREPPB','', '',FALSE,'',
l_conc_id,554,G_comb_pdr_temp,
G_comb_pdr_locale,'Y','RTF','',scale_report,'','','','','',
When i saw XML Report Publisher concurrent program, there is one parameter for Output Format and i tried passing 'Excel'/EXCEL/excel to this parameter but output is still coming in PDF format.
FND_REQUEST.SUBMIT_REQUEST('XDO','XDOREPPB','', '',FALSE,'',
l_conc_id,554,G_comb_pdr_temp,
G_comb_pdr_locale,'Y','RTF','Excel',scale_report,'','','','','',
I have also tried giving Default Output to EXCEL in template definition but this is also not working.
Your valuable suggestions highly appreciated.
Thanks
VijayHi;
What is EBS version? Please see below which could be helpful for your issue:
Changing Output Format to RTF or Excel in XML Publisher Request Does Not Display Output Correctly [ID 404512.1]
Cannot View BI Publisher (formerly XML Publisher) Report Output In Excel Format or XHTML [ID 359875.1
How is Default Output Type Determined for Reports Submitted Using XML [ID 888972.1]
Also see:
XML PUBLISHER report in Excel out put problem
XML PUBLISHER report in Excel out put problem
Regard
Helios -
How to correct bad PDF display of Excel 2007 graph-Adobe Pro X?
Just installed Adobe Acrobat Pro X; previously had Adobe Pro 8, which worked fine. Have Excel 2007 files with an Excel graph and a JPG image on the spreadsheet tab. Both the graph and the JPG are too big, are displaced, and hide spreadsheet data, when the Excel file is Saved As a PDF using Adobe Pro dialog or Excel dialog, or the Excel Plug-In to Create PDF. For some strange reason, printing to PDF works, although that is limiting. All of the settings are the same for the Adobe Printer as Adobe Pro settings. Changing them or going to default did not help. Just did the latest update; that did not help.
The graph and JPG are too large for the PDF page. Paper printing from Excel still works fine. Producing a PDF on another machine with Pro 8 still works fine. Could not find this problem discussed anywhere. Using XP, fully patched. This should not be a complicated process, nor a complex spreadsheet. What is going on?
ThanksRegardless of the method and Adobe product used to create the PDF, including the Excel tool button, the single common factor whether the PDF correctly displays a JPG or graph in the Excel file that is being done at anything other than 100% size is whether the Adobe Printer or a Physical Printer is selected as the default printer in the Windows Printers and Faxes-Settings. This is true even though the printer is not being used. I have created the same PDF using every method/product and the results are always the same, and only properly display when either the setting is 100% size or the system printer is selected as Adobe Printer. This is true only after installing Adobe X (8 was previously installed, and worked as expected).
Jeffry Calhoun
Workforce Analytics Manager
Ohio Department of Job & Family Services
P.O. Box 1618, Columbus, OH 43216-1618
InterAgency: F376, 4020 E. 5th Avenue
614-644-0564
Fax 614-728-5938
[email protected]
OhioMeansJobs.com -
The next best thing to having an HR department.
OhioMeansJobs.com -
Ohio's premier website for connecting businesses and job seekers - quickly, easily, and for free!
>>> "Bill@VT" <[email protected]> 4/7/2012 7:21 AM >>>
Re: How to correct bad PDF display of Excel 2007 graph-Adobe Pro X? created by Bill@VT ( http://forums.adobe.com/people/Bill%40VT ) in Creating, Editing & Exporting PDFs - View the full discussion ( http://forums.adobe.com/message/4319297#4319297 )
You say the settings for the printer work fine, but do not for PDF Maker (I am assuming this is what you meant). PDF Maker no longer uses the printer and the settings are independent. Check the settings for PDF Maker under the create PDF menu.
Replies to this message go to everyone subscribed to this thread, not directly to the person who posted the message. To post a reply, either reply to this email or visit the message page: http://forums.adobe.com/message/4319297#4319297
To unsubscribe from this thread, please visit the message page at http://forums.adobe.com/message/4319297#4319297. In the Actions box on the right, click the Stop Email Notifications link.
Start a new discussion in Creating, Editing & Exporting PDFs by email ( mailto:discussions-community-acrobat-creating__editing_%[email protected] ) or at Adobe Forums ( http://forums.adobe.com/choose-container!input.jspa?contentType=1&containerType=14&contain er=4697 )
For more information about maintaining your forum email notifications please go to http://forums.adobe.com/message/2936746#2936746.
Ohio Means Jobs
You're looking for something unique. Use more than an ordinary site.
http://www.ohiomeansjobs.com
This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and may contain private, confidential, and/or privileged information. Any unauthorized review, use, disclosure, or distribution is prohibited. If you are not the intended recipient, employee, or agent responsible for delivering this message, please contact the sender by reply e-mail and destroy all copies of the original e-mail message. -
Hello,
I have an ALV report. The output of the report is OK. But, when I see it in Excel view(Ctrl + Shift + F7), then also data output is coming in the proper format. But, the only problem is I don't see my Header informations(Report Headings/Subheading) in any of the sheet even not in the RAWHEADER sheet also. Does anybody have any idea why the Header informations are not coming in Excel view.
Thanks and regards,
Ajay Ahujahi ajay,
In the EXCEL VIEW u have the HEADER as the FIRST ROW IN EXCEL SHEET..
i have sent a sample code of mine..u can check it also... hope u will have ur problem solved..
TYPE-POOLS slis.
TYPES :BEGIN OF ty_mm,
sl_no type i,
werks TYPE marc-werks,
matnr TYPE mara-matnr,
maktx TYPE makt-maktx,
mtart TYPE mara-mtart,
volum TYPE mara-volum,
ntgew TYPE mara-ntgew,
ersda TYPE mara-ersda,
laeda TYPE mara-laeda,
END OF ty_mm.
DATA : it_mm TYPE TABLE OF ty_mm,
wa_mm TYPE ty_mm.
field catalog declaration, only if u do so u can display heading in alv
DATA : it_fc TYPE slis_t_fieldcat_alv,
wa_fc TYPE slis_fieldcat_alv.
PARAMETERS : p_werks TYPE marc-werks.
SELECT marc~werks
mara~matnr
makt~maktx
mara~mtart
mara~volum
mara~ntgew
mara~ersda
mara~laeda
FROM marc
INNER JOIN mara ON marcmatnr = maramatnr
INNER JOIN makt ON maramatnr = maktmatnr
INTO CORRESPONDING FIELDS OF TABLE it_mm
WHERE marc~werks = p_werks and spras = 'EN'.
loop at it_mm into wa_mm.
wa_mm-sl_no = sy-tabix.
modify it_mm from wa_mm transporting sl_no .
endloop.
this is how u append the header to an alv grid
wa_fc-col_pos = 1.
wa_fc-seltext_l = 'SLNO'.
wa_fc-fieldname = 'SL_NO'.
wa_fc-tabname = 'IT_MM'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 2.
wa_fc-fieldname = 'WERKS'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='WERKS'.
wa_fc-ref_tabname = 'MARC'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 3.
wa_fc-fieldname = 'MATNR'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='MATNR'.
wa_fc-ref_tabname = 'MARA'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 4.
wa_fc-fieldname = 'MAKTX'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='MAKTX'.
wa_fc-ref_tabname = 'MAKT'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 5.
wa_fc-fieldname = 'MTART'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='MTART'.
wa_fc-ref_tabname = 'MARA'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 6.
wa_fc-fieldname = 'VOLUM'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='VOLUM'.
wa_fc-ref_tabname = 'MARA'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 7.
wa_fc-fieldname = 'NTGEW'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='NTGEW'.
wa_fc-ref_tabname = 'MARA'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 8.
wa_fc-fieldname = 'ERSDA'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='ERSDA'.
wa_fc-ref_tabname = 'MARA'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
wa_fc-col_pos = 9.
wa_fc-fieldname = 'LAEDA'.
wa_fc-tabname = 'IT_MM'.
wa_fc-ref_fieldname ='LAEDA'.
wa_fc-ref_tabname = 'MARA'.
wa_fc-hotspot = 'X'.
APPEND wa_fc TO it_fc.
CLEAR wa_fc.
fn module to display alv grid
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = sy-repid
i_grid_title = 'PLANT'
it_fieldcat = it_fc[]
TABLES
t_outtab = it_mm
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.
regards
Rajkumar.G -
Hi
In my alv grid display i am not able to view the content in excel view .how to solve this problem?Hi
There will be something wrong with the PF status which you are using
Take some STd ALV report and copy its status to your report and use that
it will come
Regards
anji -
Hi All,
I have a problem with the ALV display problem.
When I click on the 'Microsoft Excel View' button at the top of the ALV display, I can view the data in Excel View.
However, when my user click it on his computer, he saw the excel view is blank without data (even there are data at the initial ALV display screen).
May I know what is the root cause of this problem? I've no idea of how to investigate it or solve it.
Many Thanks.HI try with this code------
*& Report ZTEST_DOWNLOAD1
report ztest_download1.
tables : trdir.
type-pools: slis.
types: begin of gt_output,
progname type progname,
strct_type(14) type c,
strct_name(50) type c,
serial(8) type c,
mainfieldname(50) type c,
offset(17) type c,
leng(8) type c,
decimals(8) type c,
inttype(15) type c,
datatype(9) type c,
scrtext_m type scrtext_m,
tabname type tabname,
fieldname type fieldname,
rollname type rollname,
domname type domname,
default(100) type c,
end of gt_output.
types: begin of gt_header,
name(300) type c,
end of gt_header.
data : gi_output type standard table of gt_output,
wa_output type gt_output,
gi_header type standard table of gt_header.
data: d_filename like ibipparms-path,
gi_fieldcat type slis_t_fieldcat_alv,
wa_fieldcat type slis_fieldcat_alv,
wa_header type gt_header.
selection-screen:
begin of block b1 with frame title text-001.
parameter: program(150) type c default 'ZTOOL_TEST'.
select-options so_incl for trdir-name default 'ztool_test' no intervals .
selection-screen begin of line.
parameters :pa_check as checkbox default 'X'.
selection-screen comment (29) text-t01.
parameters :pa_path type rlgrap-filename default 'D:\TRIAL.XLS'.
selection-screen end of line.
selection-screen end of block b1.
at selection-screen.
perform download_excel_template.
at selection-screen on value-request for pa_path.
perform f4_file_help.
*& Form F4_file_help
text
--> p1 text
<-- p2 text
form f4_file_help .
call function 'KD_GET_FILENAME_ON_F4'
exporting
program_name = sy-repid
dynpro_number = syst-dynnr
field_name = pa_path
changing
file_name = d_filename
exceptions
mask_too_long = 1
others = 2.
if sy-subrc <> 0.
MESSAGE ID gv_msgid TYPE 'I' NUMBER 000.
endif.
endform. "f4_file_help
form download_excel_template .
refresh gi_header.
wa_header-name = text-t01.
append wa_header to gi_header.
wa_header-name = text-t02.
append wa_header to gi_header.
wa_header-name = text-t03.
append wa_header to gi_header.
wa_header-name = text-t04.
append wa_header to gi_header.
wa_header-name = text-t05.
append wa_header to gi_header.
wa_header-name = text-t06.
append wa_header to gi_header.
wa_header-name = text-t07.
append wa_header to gi_header.
wa_header-name = text-t08.
append wa_header to gi_header.
wa_header-name = text-t09.
append wa_header to gi_header.
wa_header-name = text-t10.
append wa_header to gi_header.
wa_header-name = text-t11.
append wa_header to gi_header.
wa_header-name = text-t12.
append wa_header to gi_header.
wa_header-name = text-t13.
append wa_header to gi_header.
wa_header-name = text-t14.
append wa_header to gi_header.
wa_header-name = text-t15.
append wa_header to gi_header.
wa_header-name = text-t16.
append wa_header to gi_header.
wa_output-strct_name = 'abc'.
append wa_output to gi_output.
call function 'MS_EXCEL_OLE_STANDARD_DAT'
exporting
file_name = pa_path
data_sheet_name = 'Structure details'
tables
data_tab = gi_output
fieldnames = gi_header
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 ID gv_msgid TYPE 'E' NUMBER 002.
endif.
endform. " DOWNLOAD_EXCEL_TEMPLATE
regards
prashant -
To Display Report in a ALV GRID Format
Hi All,
I want to display dome information in ALV Grid format.
Can anybody give example for displaying data in ALV Grid Format.
Thanks in advance.
Thanks & Regards,
Rayeez.Hi ,
1.FOR ALV Lists..
REPORT Y_DEMO_ALV NO STANDARD PAGE HEADING.
Data to be displayed
DATA: I_SFLIGHT TYPE TABLE OF SFLIGHT.
Selection
SELECT * FROM SFLIGHT INTO TABLE I_SFLIGHT.
Call ABAP List Viewer (ALV)
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
I_STRUCTURE_NAME = 'SFLIGHT'
TABLES
T_OUTTAB = I_SFLIGHT.
2.Using Grids..
REPORT Y_DEMO_ALV_1.
Data to be displayed
DATA: I_SFLIGHT TYPE TABLE OF SFLIGHT.
Selection
SELECT * FROM SFLIGHT INTO TABLE I_SFLIGHT.
Call ABAP List Viewer (ALV)
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_STRUCTURE_NAME = 'SFLIGHT'
TABLES
T_OUTTAB = I_SFLIGHT.
3.Demo Using most of the ALv Functionalities..
REPORT ZSATTRIAL4.
TYPE-POOLS: slis.
DB-Table
TABLES sflight.
Includes
INCLUDE <icon>.
INCLUDE <symbol>.
CONSTANTS:
c_formname_top_of_page TYPE slis_formname VALUE 'TOP_OF_PAGE'.
DATA: i_fieldcat TYPE slis_t_fieldcat_alv,
i_layout TYPE slis_layout_alv,
i_sp_group TYPE slis_t_sp_group_alv,
i_events TYPE slis_t_event,
i_print TYPE slis_print_alv,
i_sort TYPE slis_t_sortinfo_alv.
*internal table for data to be displayed
DATA: BEGIN OF i_sflight OCCURS 0.
INCLUDE STRUCTURE sflight.
DATA: box,
lights.
DATA: END OF i_sflight.
DATA: w_repid LIKE sy-repid.
DATA: i_list_top_of_page TYPE slis_t_listheader.
Report Selections
SELECT-OPTIONS s_carrid FOR sflight-carrid.
SELECT-OPTIONS s_connid FOR sflight-connid.
SELECT-OPTIONS s_fldate FOR sflight-fldate.
*SELECTION-SCREEN SKIP 1.
Parameters
PARAMETERS: p_maxrow TYPE i DEFAULT 30."to limit the selection
SELECTION-SCREEN SKIP 1.
Variant for ALV display
SELECTION-SCREEN BEGIN OF BLOCK 0 WITH FRAME TITLE text-000.
PARAMETERS: p_varnt LIKE disvariant-variant.
SELECTION-SCREEN END OF BLOCK 0.
Layout of the report display
SELECTION-SCREEN BEGIN OF BLOCK a WITH FRAME TITLE text-001.
PARAMETERS: p_zebra AS CHECKBOX DEFAULT ' ', "Striped pattern
p_nocolh AS CHECKBOX DEFAULT ' ', "No column heading
p_novlin AS CHECKBOX DEFAULT ' ', "No vertical lines
p_colopt AS CHECKBOX DEFAULT ' ', "Optimizes col. wd
p_keyhot AS CHECKBOX DEFAULT ' ', "Key fields hot
p_noinpt AS CHECKBOX DEFAULT ' '. "No field for input
SELECTION-SCREEN END OF BLOCK a.
SELECTION-SCREEN BEGIN OF BLOCK b WITH FRAME TITLE text-002.
PARAMETERS: p_lights AS CHECKBOX DEFAULT 'X',
p_lightc AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN END OF BLOCK b.
SELECTION-SCREEN BEGIN OF BLOCK c WITH FRAME TITLE text-003.
PARAMETERS: p_totonl AS CHECKBOX DEFAULT ' ',
p_totext(60),
p_sttext(60).
SELECTION-SCREEN END OF BLOCK c.
SELECTION-SCREEN BEGIN OF BLOCK d WITH FRAME TITLE text-004.
PARAMETERS: p_chkbox AS CHECKBOX DEFAULT 'X',
p_detpop AS CHECKBOX DEFAULT 'X',
p_groupb AS CHECKBOX DEFAULT ' ',
p_groups AS CHECKBOX DEFAULT ' '.
SELECTION-SCREEN END OF BLOCK d.
SELECTION-SCREEN BEGIN OF BLOCK e WITH FRAME TITLE text-005.
PARAMETERS: p_print AS CHECKBOX DEFAULT ' ',
p_nosinf AS CHECKBOX DEFAULT ' ',
p_nocove AS CHECKBOX DEFAULT ' ',
p_nonewp AS CHECKBOX DEFAULT ' ',
p_nolinf AS CHECKBOX DEFAULT ' ',
p_reserv TYPE i.
SELECTION-SCREEN END OF BLOCK e.
DATA: w_boxnam TYPE slis_fieldname VALUE 'BOX',
w_f2code LIKE sy-ucomm VALUE '&ETA',
w_lignam TYPE slis_fieldname VALUE 'LIGHTS',
w_save(1) TYPE c,
w_default(1) TYPE c,
w_exit(1) TYPE c,
i_variant LIKE disvariant,
i_variant1 LIKE disvariant.
INITIALIZATION.
w_repid = sy-repid.
PERFORM fieldcat_init USING i_fieldcat.
PERFORM eventtab_build USING i_events.
PERFORM comment_build USING i_list_top_of_page.
PERFORM sp_group_build USING i_sp_group.
PERFORM t_sort_build USING i_sort.
Set Options: save variant userspecific or general
'A or 'U' are for user-specific variants list
'X' or 'space' for general
w_save = 'A'.
PERFORM variant_init.
Get default variant
i_variant1 = i_variant.
CALL FUNCTION 'REUSE_ALV_VARIANT_DEFAULT_GET'
EXPORTING
i_save = w_save
CHANGING
cs_variant = i_variant1
EXCEPTIONS
not_found = 2.
IF sy-subrc = 0.
p_varnt = i_variant1-variant.
ENDIF.
Process on value request (list of possible variants)
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_varnt.
PERFORM f4_for_variant.
PAI
AT SELECTION-SCREEN.
PERFORM pai_of_selection_screen.
START-OF-SELECTION.
PERFORM selection.
END-OF-SELECTION.
PERFORM layout_build USING i_layout. "wg. Parameters
PERFORM print_build USING i_print. "wg. Parameters
CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE'
EXPORTING
i_program_name = w_repid
i_internal_tabname = 'I_SFLIGHT'
i_structure_name = 'SFLIGHT'
i_client_never_display = 'X'
i_inclname = w_repid
CHANGING
ct_fieldcat = i_fieldcat[]
EXCEPTIONS
inconsistent_interface = 1
program_error = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE 'S' NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
Call ABAP/4 List Viewer
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
i_callback_program = w_repid
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = ' '
I_CALLBACK_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_END_OF_LIST = ' '
i_structure_name = 'SFLIGHT'
i_background_id = 'ALV_BACKGROUND'
I_GRID_TITLE =
I_GRID_SETTINGS =
is_layout = i_layout
it_fieldcat = i_fieldcat[]
IT_EXCLUDING =
it_special_groups = i_sp_group[]
it_sort = i_sort[]
IT_FILTER =
IS_SEL_HIDE =
I_DEFAULT = 'X'
i_save = w_save
is_variant = i_variant
it_events = i_events[]
IT_EVENT_EXIT =
is_print = i_print
IS_REPREP_ID =
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
ES_EXIT_CAUSED_BY_USER =
TABLES
t_outtab = i_sflight
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.
CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
EXPORTING
i_callback_program = w_repid
i_structure_name = 'SFLIGHT'
is_layout = i_layout
it_fieldcat = i_fieldcat[]
IT_EXCLUDING =
it_special_groups = i_sp_group[]
it_sort = i_sort[]
IT_FILTER =
IS_SEL_HIDE =
i_default = W_DEFAULT
i_save = w_save
is_variant = i_variant
it_events = i_events[]
IT_EVENT_EXIT =
is_print = i_print
I_SCREEN_START_COLUMN = 0
I_SCREEN_START_LINE = 0
I_SCREEN_END_COLUMN = 0
I_SCREEN_END_LINE = 0
IMPORTING
E_EXIT_CAUSED_BY_CALLER =
TABLES
t_outtab = i_sflight.
FORM FIELDCAT_INIT *
--> L_FIELDCAT *
FORM fieldcat_init USING l_fieldcat TYPE slis_t_fieldcat_alv.
DATA: ls_fieldcat TYPE slis_fieldcat_alv.
CLEAR ls_fieldcat.
ls_fieldcat-fieldname = 'SEATSOCC'.
*The field is not displayed in the initial output, can be interactively
chosen for display
ls_fieldcat-no_out = 'X'.
*This field is assigned to a special group with tech. key 'A' and can be
*displayed using the special group buttons
ls_fieldcat-sp_group = 'A'.
*The field cannot be summed irrespective of its data type
ls_fieldcat-no_sum = 'X'.
APPEND ls_fieldcat TO l_fieldcat.
CLEAR ls_fieldcat.
ls_fieldcat-fieldname = 'SEATSMAX'.
ls_fieldcat-no_out = 'X'.
ls_fieldcat-sp_group = 'A'.
APPEND ls_fieldcat TO l_fieldcat.
CLEAR ls_fieldcat.
ls_fieldcat-fieldname = 'PRICE'.
ls_fieldcat-no_out = 'X'.
ls_fieldcat-sp_group = 'B'.
APPEND ls_fieldcat TO l_fieldcat.
CLEAR ls_fieldcat.
ls_fieldcat-fieldname = 'CARRID'.
ls_fieldcat-outputlen = 7.
APPEND ls_fieldcat TO l_fieldcat.
ENDFORM.
FORM DATA_ADD *
--> L_SFLIGHT
FORM data_add TABLES l_sflight STRUCTURE i_sflight.
LOOP AT l_sflight.
IF sy-tabix > 10.
l_sflight-box = 'X'.
l_sflight-lights = '3'.
ELSE.
IF sy-tabix = 1.
l_sflight-lights = '2'.
ELSE.
l_sflight-lights = '1'.
ENDIF.
ENDIF.
MODIFY l_sflight.
ENDLOOP.
ENDFORM.
FORM EVENTTAB_BUILD *
--> l_EVENTS *
FORM eventtab_build USING l_events TYPE slis_t_event.
DATA: ls_event TYPE slis_alv_event.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
i_list_type = 0
IMPORTING
et_events = l_events.
READ TABLE l_events WITH KEY name = slis_ev_top_of_page INTO ls_event.
IF sy-subrc = 0.
MOVE c_formname_top_of_page TO ls_event-form.
APPEND ls_event TO l_events.
ENDIF.
ENDFORM.
FORM COMMENT_BUILD *
--> L_TOP_OF_PAGE *
FORM comment_build USING l_top_of_page TYPE slis_t_listheader.
DATA: ls_line TYPE slis_listheader.
***Header
CLEAR ls_line.
ls_line-typ = 'H'.
LS_LINE-KEY: not used for this type
ls_line-info = 'Heading list'.
APPEND ls_line TO l_top_of_page.
***Selection
CLEAR ls_line.
ls_line-typ = 'S'.
ls_line-key = 'Key 1'.
ls_line-info = 'Information'.
APPEND ls_line TO l_top_of_page.
ls_line-key = 'Key 2'.
APPEND ls_line TO l_top_of_page.
***Action
CLEAR ls_line.
ls_line-typ = 'A'.
LS_LINE-KEY: not used for this type
Ls_line-info = 'Status list'.
APPEND ls_line TO l_top_of_page.
ENDFORM.
FORM LAYOUT_BUILD *
<-> LS_LAYOUT *
FORM layout_build USING ls_layout TYPE slis_layout_alv.
ls_layout-f2code = w_f2code.
ls_layout-zebra = p_zebra.
ls_layout-colwidth_optimize = p_colopt.
IF p_chkbox = 'X'.
*Fieldname for check box on the report output
ls_layout-box_fieldname = w_boxnam.
ELSE.
ls_layout-box_fieldname = space.
ENDIF.
ls_layout-no_input = p_noinpt.
ls_layout-no_vline = p_novlin.
ls_layout-no_colhead = p_nocolh.
IF p_lights = 'X' OR p_lightc = 'X'.
**Fieldname for lights on the report output
ls_layout-lights_fieldname = w_lignam.
ELSE.
CLEAR ls_layout-lights_fieldname.
ENDIF.
ls_layout-lights_condense = p_lightc.
ls_layout-totals_text = p_totext.
ls_layout-subtotals_text = p_sttext.
ls_layout-totals_only = p_totonl.
ls_layout-key_hotspot = p_keyhot.
ls_layout-detail_popup = p_detpop.
ls_layout-group_change_edit = p_groups.
E05_LS_LAYOUT-GROUP_BUTTONS = P_GROUPB.
ls_layout-group_buttons = 'X'.
ENDFORM.
FORM SP_GROUP_BUILD *
--> L_SP_GROUP *
FORM sp_group_build USING l_sp_group TYPE slis_t_sp_group_alv.
DATA: ls_sp_group TYPE slis_sp_group_alv.
*Fields are assigned to the special group
CLEAR ls_sp_group.
ls_sp_group-sp_group = 'A'.
ls_sp_group-text = 'Reservation status'.
APPEND ls_sp_group TO l_sp_group.
CLEAR ls_sp_group.
ls_sp_group-sp_group = 'B'.
ls_sp_group-text = 'Flight charges'.
APPEND ls_sp_group TO l_sp_group.
ENDFORM.
FORM SELECTION *
FORM selection.
SELECT * FROM sflight INTO CORRESPONDING FIELDS OF TABLE i_sflight
UP TO p_maxrow ROWS WHERE carrid IN s_carrid
AND connid IN s_connid AND fldate IN s_fldate.
PERFORM data_add TABLES i_sflight.
ENDFORM.
FORM TOP_OF_PAGE *
FORM top_of_page.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
i_logo = 'ENJOYSAP_LOGO'
it_list_commentary = i_list_top_of_page.
ENDFORM.
FORM F4_FOR_VARIANT *
FORM f4_for_variant.
CALL FUNCTION 'REUSE_ALV_VARIANT_F4'
EXPORTING
is_variant = i_variant
i_save = w_save
it_default_fieldcat =
IMPORTING
e_exit = w_exit
es_variant = i_variant1
EXCEPTIONS
not_found = 2.
IF sy-subrc = 2.
MESSAGE ID sy-msgid TYPE 'S' NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ELSE.
IF w_exit = space.
p_varnt = i_variant1-variant.
ENDIF.
ENDIF.
ENDFORM.
*& Form PAI_OF_SELECTION_SCREEN
to check whether right variant is entered on the selection scr
FORM pai_of_selection_screen.
IF NOT p_varnt IS INITIAL.
MOVE i_variant TO i_variant1.
MOVE p_varnt TO i_variant1-variant.
CALL FUNCTION 'REUSE_ALV_VARIANT_EXISTENCE'
EXPORTING
i_save = w_save
CHANGING
cs_variant = i_variant1.
i_variant = i_variant1.
ELSE.
PERFORM variant_init.
ENDIF.
ENDFORM. " PAI_OF_SELECTION_SCREEN
*& Form VARIANT_INIT
FORM variant_init.
CLEAR i_variant.
i_variant-report = w_repid.
ENDFORM. " VARIANT_INIT
FORM PRINT_BUILD *
FORM print_build USING l_print TYPE slis_print_alv.
l_print-print = p_print.
l_print-no_print_selinfos = p_nosinf.
l_print-no_coverpage = p_nocove.
l_print-no_new_page = p_nonewp.
l_print-no_print_listinfos = p_nolinf.
l_print-reserve_lines = p_reserv.
l_print-print = p_print.
ENDFORM.
FORM T_SORT_BUILD *
FORM t_sort_build USING l_sort TYPE slis_t_sortinfo_alv.
DATA: ls_sort TYPE slis_sortinfo_alv.
ls_sort-fieldname = 'CARRID'.
ls_sort-spos = 1.
ls_sort-up = 'X'.
ls_sort-subtot = 'X'.
APPEND ls_sort TO l_sort.
ps : reward points for helpful answers and mark the post as closed.. -
Issue using SharePoint 2010 with IE10 with MS Office Excel Viewer
Hello,
We are experiencing an issue with MS SharePoint 2010 Foundation and computers who have Internet Explorer 10 and the Microsoft Office Word Viewer 2003. When opening Word documents from SharePoint, the Word Viewer opens, but no document is displayed.
The MS Excel Viewer 2007 works and does open the Excel documents.
Computers with MS Word Viewer 2003 and IE 9 works fine, it's just the IE10 PCs. PCs that have the full version of Office it works fine with both IE9 and IE10.
We have a segment of our PCs that need only read-only access to the Word and Excel files. We tried Office Web App but found functionality issues (printing, etc.) and issues where the other segment of our PCs that have MS Office had to open the files
in a specific way to manipulate them.
Does anyone know of something that would be affecting the MS Word Viewer with IE10 with SharePoint? Or know of an alternate viewer?
Thanks in advance.Hello Anthony,
In IE10, please click F12 to open the DEV toolbar.
Now search for Browser- and Document Mode.
Set Browser Mode to Internet Explorer 8, that should work.
This setting can be edited in your Masterpage.
This is what you should put in:
<meta
http-equiv="X-UA-Compatible" content="IE=8" /> -
TranslateMarkup output not displaying in design view
Hi
I'm trying to take a set of php pages which all follow a similar style
<?php
$p=new page();
$p->rightCol=<<<RC
SOME HTML GOES HERE
RC;
$p->mainContent=<<<MC
SOME OTHER HTML GOES HERE
MC;
This then pulls in various other files (css, js etc) and renders on the website. I'm used to working with an IDE and hand-writing php code. My non-technical colleague would like to edit the html using WYSIWYG and is used to using DW. At the moment the html in the heredoc strings doesn't display in design view. I've been trying to rejig the pages using translators and can convert the above php into html which renders fine in a browser. The html output from the translateMarkup function doesn't display in design view. I think I'm probably fighting a losing battle (for instance I'm not sure how I'm going to make html editable in DW even if I can get it to render), but if anyone could explain why the html won't render I'd be very grateful. My translator is
<html>
<head>
<title>Conditional Translator</title>
<meta http-equiv="Content-Type" content="text/html; charset=">
<script language="JavaScript">
function translateMarkup(docNameStr, siteRootStr, docContent){
//Find the right col stuff, delimited by <<<RC\n and RC;\n
var regexRC=/<<RC([\s\S]*)RC;/;
var regexMC=/<<MC([\s\S]*)MC;/;
var rcContent = regexRC.exec(docContent)[1];
var mcContent = regexMC.exec(docContent)[1];
var ret = (getHeader()+'<main>'+mcContent+'</main><aside id="rightcol">'+rcContent+'</aside>'+getFooter());
return ret;
function getTranslatorInfo() {
var transArray = new Array(6);
transArray[0] = "LG_TRANS";
transArray[1] = "Translates for LG";
transArray[2] = "1";
transArray[3] = "php";
transArray[4] = "0";
transArray[5] = "allFiles";
transArray[6] = "50";
return transArray;
function getHeader() {
return '<!DOCTYPE html><html><head><title>TEST</title></head><body>';
function getFooter() {
return '</body></html>';
</script>
</head>
<body>
</body>
</html>unless there's any way of rewriting the files before upload and download (ie dynamically rewrite the php pages as html before dreamweaver opens them, then rewrite them back as php before they're uploaded - I'm clutching at straws).
I believe that this should be possible but I'm definitely not a DW extensionologist so I couldn't say for sure. Also, I believe that the tricky part would be the last step -> WYSIWYG edits back to PHP, which may well be impossible.
If you want to talk to someone who knows DW inside out, contact the guys at http://www.projectseven.com. They are excellent. -
How to open an ALV (the OO way) in Excel-View right away?
Dear experts,
i'm creating an ALV Grid by using method set_table_for_first_display and I wonder if I can initially choose the Excel-view for it as if the user had switched over to it by using the standard "view" function. I figured that this might be posible by using the "FRONTEND" field in the Layout-structure, but this has no efect. Does anybody know how to do that? (if possible without creating an instance of the office integration class).
regards
AndreasYeah, it is possible
Check this code
* Container auxiliar
create object g_o_container
exporting
container_name = 'G_D_CONTAINER'
exceptions
cntl_error = 1
cntl_system_error = 2
create_error = 3
lifetime_error = 4
lifetime_dynpro_dynpro_link = 5
others = 6.
create object g_d_grid
exporting
i_parent = g_o_container
i_parentdbg = cl_gui_custom_container=>default_screen
exceptions
error_cntl_create = 1
error_cntl_init = 2
error_cntl_link = 3
error_dp_create = 4
others = 5.
endif.
perform layout.
perform fieldcat.
call method g_d_grid->set_table_for_first_display
exporting
is_layout = gs_layout
* is_print =
* it_special_groups =
* it_toolbar_excluding =
changing
it_outtab = g_t_alv
it_fieldcatalog = g_t_fieldcatalog
exceptions
invalid_parameter_combination = 1
program_error = 2
too_many_lines = 3
others = 4
The key is using the i_parentdbg parameter when creating the ALV Grid, it's kind of a trick, but it worked for me.
Maybe you are looking for
-
Oracle 11i Fixed Assets - Additions Error Message Company is not value
I have created Fixed Assets Corporate Book and trying to add a new record through Assets Workbench and Addition Option. When I try to create information in Assignment Detail to enter Expenses Account and I am selecting Expense Account but getting Mes
-
Report Painter "Library FAGLFLEXT"
Hello Experts, Im current making a Income statement report on the report painter.. Using library "FAGLFLEXT" my requirement is to have the Profit Center as the Characteristic on the Column. And the GL account and Cost Centers on the row... But the re
-
When do different scopes get removed from memory?
Hi, Here's what I've got. I have a cfc that processes complex xml documents for product catalogs. We've got functions in that cfc to process various parts of each document, with parts being passed to the function (product object struct, option stru
-
Hi, we modified CO-PA data source in R/3 and replicated the changes to BW.Initially the update mode was a delta. We created a infopackage for full load and loaded the entire data.After that we performed a initial delta process by checking initialize
-
ReadOnly attribute not showing
I'm trying to create two views of a page where one is readonly and another one is editable. The form page does the following: <h:commandLink value="Create Record" action="#{Bean.readOnlyAccess}">