on 09-17-2005 1:58 AM
Hello BW Experts,
How to enchance Web Printing document describes to use print functionality from Context Menu.
I have done the following things in sequence as mentioned in the paper.
1) Added the following code for the context menu
<object>
<param name="OWNER" value="SAP_BW"/>
<param name="CMD" value="SET_PROPERTIES"/>
<param name="TEMPLATE_ID" value="Z_TEST"/>
<param name="SUPPRESS_SYSTEM_MESSAGES" value="X"/>
<param name="SUPPRESS_WARNINGS" value="X"/>
<param name="VARIABLE_SCREEN" value="X"/>
<param name="CMENU_LABEL" value="Print"/>
<param name="CMENU_FUNCTION" value="callPrintHelpService"/>
TEMPLATE PROPERTIES
</object>
-
2) Added the Javascript function
<script>
<script language=javascript>
function callPrintHelpService(parameter, cell_type, filter, parameter1, parameter2, item, dataprovider, x, y) {
var url = SAP_BW_URL_Get();
var print_service = "Z_PRINT_HELP_SERVICE"
if ( parameter == "inches") print_service = "Z_PRINT_HELP_SERVICE_IMP";
var cmd = url + "&DATA_PROVIDER=DATAPROVIDER_9&HELP_SERVICE_CLASS=" + print_service;
SAP_BW_URL_Get();
<!var logo = "'&IMG:Mime/BEx/Icons/KODAK_corp.jpg&'";->
url = url + "&CMD=PROCESS_HELP_WINDOW&HELP_SERVICE=ZPRINTING&DATA_PROVIDER=DATAPROVIDER_9&P_HEADER_LEFT=";
url = url + logo ;
url = url + "&P_STYLESHEET=/sap/bw/mime/BEx/StyleSheets/BWReports_smallfont_print.css&P_PAGE_WIDTH=29&P_PAGE_HEIGHT=18&P_HEADER_CENTER=Restricted Information";
if( dataprovider == "DATAPROVIDER_9") window.open(url, "Print", "width=800, height=600, menubar=yes, toolbar=no, scrollbars=yes, resizable=yes"); }
</script>
-
When I click the Print in the context menu, printing does not happen.
-- Am I missing the call to the javasript function ?
-- Wondering if the call to the javasricpt function should be different (should contain the paramters to the fucntion)
-- Is there any alternate method to achieve the print functionality from context menu.
Please share your experiences with the print functionality of web templates. Any experiences of print functionality would be helpful. Appreciate your suggestions.
Thanks,
BWer
Hi,
why u have used 2 <script> tags in your application? is it by mistake you wrote here? please check is this the part of your application too.
Regards,
Kamaljeet
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi
if you need the printable version of the query, create the printable template same as the query
function printable(targ1)
{
eval(targ1".location='""<SAP_BW_URL CMD_1="CMD=change_Template&TEMPLATE_ID=PrintabletemplateID" CMD_2="ITEM=TABLE&BLOCK_SIZE=0" CMD_3="ITEM=TABLE&GENERATE_LINKS=" >"+"'");
}
</table>
<table width="99%" border="1" height="292">
<tr>
<td height="487" align="left" valign="top" colspan="3"><object>
<param name="OWNER" value="SAP_BW"/>
<param name="CMD" value="GET_ITEM"/>
<param name="NAME" value="TABLE"/>
<param name="ITEM_ID" value="TABLE"/>
<param name="DATA_PROVIDER" value="COPA_VAL"/>
<param name="CAPTION" value="BW VALIDATION"/>
<param name="HELP_SERVICE" value="ZPRINTING"/>
<param name="HELP_SERVICE_CLASS" value="Z_PRINT_HELP_SERVICE"/>
<param name="MODIFY_CLASS" value="ZCL_TABLE_CLASS"/>
ITEM: TABLE
</object></td>
</tr>
Hope this may help you
Rgrds
Reddy
User | Count |
---|---|
84 | |
9 | |
9 | |
8 | |
7 | |
7 | |
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.