Delivery Print Preview
Hi,
Whenever I am trying to see Delivery print Preview or taking a Printout of Delivery at LOCAL Printer.
At the background of Delivery " Copy" is printed & which hides the contents of Delivery.
Please advise how can we remove "Copy" from delivery.
Thanks & Regards,
Vikas
Dear Vikas,
Check the Smartform attached to your Output type of Delivery from T-Code - V/83.
Then ask your ABAPer to change / modify the Smartform thru t-code Smartforms.
Hope this helps...
Reward if useful..
Thanks,
Jignesh Mehta
9870010230
Similar Messages
-
Print Preview of Out bound delivery is not available in VL71
Hi Experts,
I have created Outbound delivery with VL10B (against Purchase Order) and also set up output parameter in VL02N (Extra->elivery output -> Header)
Now I want to take Print out of this Outbound delivey in VL71 , I cant even see the Print preview. I have already maintained Output type , Access sequence and condition table in SPRO . I have also maintained condition record also (with delivery type and Shipping point).
Any help on thisCheck if output triggered successfully in delivery.
If yes, then please use indicator "Processing Mode" appropiately on the main selection screen of VL71.
If not, please see the error and try to resolve it.
Also check from main screen of VL02n where you enter delivery no, don't go inside the delivery screen, from main screen itself,
Outbound delivery> Issue Delivery output
Hope it helps
Regards
Anand Misra -
Delivery output print preview issue.
Hello Friends,
While going for the print preview of the outbound delivery by T-code VL71 i am getting the message-->
"Output could not be displayed (it may not be complete)
Message no. VN069"
As i have maintained VV21 & output type in the delivery.
Please help me with the solution.
Thank you.
Sadanand.hi
did u maintained the output type in NACE for appliacation V2
and also check whether u have maintained the custom form in smartforms place
Output type LD00
trans medium : 1
short tecxt : print out
Program ; RLE_DELNOTE
FORM routine : ENTRY
smartforms : ur z form
trans medium : 2
short text : fax
Program ; RLE_DELNOTE
FORM routine : ENTRY
smartforms : LE_SHP_DELNOTE
hopre this would sove ur problem.
Regards,
Venkat.
Edited by: venkatakrishnan Parthsarathy on Apr 14, 2008 2:40 PM -
Delivery Form with batch numbers and Print Preview
When I open Sales->Delivery form and select one that has items with batches, and then press Print Preview, TWO previews are automatically opened. One regular which I created using Layout designer and set as Standard, and the other called "Batches List"
Customer doesn't want the "Batches List" to use, since batches are already covered in the regular layout. Is there any way to disable it, so that only the regular preview is opened, and then printed? I'm using SAP BO 2007 A.You should change the 'When Batch/Serial No. Exists, Print' setting to 'Document Only' in Print Preferences for Delivery.
(Under menu :Administration / System Initialization / Print Preferences /Per document.) -
Problem wih delivery address on print preview
Dear experts,
I have a problem with the delivery address on the print preview.
When i create my PO and i attahced the storage location my delivery address in good in the PO and in the print preview.
When i'm not attaching the storage location the delivery address in PO is the one of the plant but in the print preview i have the different address that i do not know where its comming from.
Can you tell me which addreess in used by program as a delivery address when the storage location is not mentioned?
I thinkits that program SAPFM06P.
Thanks a lot for your help.in case of 3rd party order you have a account assignment which has the sales order number.
execute VA03 und enter the sales order number. goto the partner tab at header level and obtain which customer number is the ship-to.
the address for this customer number can be seen with XD03 transaction.
you can as well check at KNA1 table to find the address number and with address number again get the address from ADRC table. -
Delivery challan print preview for transaction j1if01 problem
hi , i have problem with print preview of delivery challan. after creating it from j1if01 im unable to get a print preview of it
as i dont find any tab or button for print preview .
plz guide me how can i get an output . also plz give form name for it . thanks !!In u2022 SPRO > Logistics - General > Tax on Goods Movements > India > Business Transactions > Subcontracting > Subcontracting Attributes maintain the Output type. Other attributes are as under fyi
Excise Group XX
Excise TT 57FC
Subtransaction Type 01
Subtran Type Text 57FC CHALLAN
Subc. Period 180
Rate-subcontracting
Mvt Grp Issues 0001
Mvt Grp Receipt 0002
Filter Non exise X
EI Items 10
No. range no. 01
***. Val. /Exc Inv
Subcon Output Type J1IF -
How to see the print preview of outgoing excise invoice.
Hi Experts,
How to see the print preview of outgoing excise invoice.
Thanks,
srinivas.Dear Sreeni,
Just go to J1IIN, click on "Exc.inv for delivery -- Display" where you input delivery reference and execute. If you have generated excise invoice, you can see the corresponding excise invoice for that delivery / billing document.
Preethi. -
Updation of table after Print and Print-Preview in smartform
Hi,
I am having a requirement where i need to print multiple deliveries with the sales order data each delivery on a new page using smartform.
Now , i am using SSF_OPEN, SSF_CLOSE Fm's for the same. I need to update a Z table after the user clicks on PRINT from the pop-up or print from the print preview screen.
I tried using the output_info parameter in the smartform where i read from a post that the OUTPUTDONE parameter becomes "X" in the job_output_info when the user clicks print wither in the two ways said before.
This does not work out in case if the FM'S SSF_OPEN and SSF_CLOSE are used.
Kindly help me on the same.
Thanks in advanceyes i tried that..using the AT new event for a Delivery and then a command to go to the NEW PAGE, but somehow when i execuet the form, i could not see the layout..so in the debug i saw the subrc after the FM is run..it says SUBRC = 2 i.e. internal error. I am not able to figure that out.
So i had to use these open and close, nowi just want to update a z table if the user clicks on the print button (print preview screen) after using the print preview .
Kindly suggest.
Thanks. -
Issue Regarding Chinese characters In Smart Form Print preview..
Hi All,
I am working on a smart form development for chinese users. The requirement is the user will login using English & when the delivery will be issued for output, a check will be done on the country of user. If that comes as china then the international version (C) maintained for that customer will come as output.
Now the problem is even if I login using EN or ZH the below issue I am facing always.
In the database I can view the details in chinese properly by logging in as ZH. During debugging also i checked the data from table ADRC & MAKT is coming in chinese properly. But when i gave the values to be output in SmartForm, it is showing the characters like how it will look if I login using EN & view the table contents.
When i view the data by changing character set as Simplified Chinese then in table i can see chinese texts properly. But when the same data goes to print preview it shows the chinese characters like as it would appear when character set is Unicode or West European..
Please help..
Thanks in advance.
Edited by: malayanayak123 on Jun 1, 2011 5:48 AMDear,
print preview and physical printout are two different things.
PrintPreview:
The data stream will be sent to the frontend and rendered with windows-fonts etc (for backend prints a simulation).
Printout:
Frontend: You need a printer, that maps the character, you have to use SAPWIN or SAPWINCF when using cascading fonts. The rendering will be done in the windows spooler.
Backend: Your printer needs also a mapping (look like something with UTF8). Also the printer needs the fonts installed because the rendering will be done in the printer!
If you use the pdf-printer in SAP, you need to upload all necessary fonts (TTF) for the pdf-composer. Also you need a unicode pdf printer for that.
Regards,
Christian -
Error while displaying print preview of smartform in VL03n
Hi all,
i created one smartform & print program . i assigned this in NACE tcode for ZD05 output type.
Then i am trying to see the print preview in VL03n while doing issue delivery output.
But i am getting error like ' Output could not be issued'. Please suggest where i am doing mistake. Thanks.
Regards
sumitraHi,
Follow below Steps:
1) Double Check your program and smartform names where you are attached in nace transaction.
2)check your templates and tables having formatting issues.
3)Finally create dummy of your smartform. then delete one by one window in smartform check it and trace out in which window error is existing.
even i faced same problem.
in my case i gave wrong line and column numbers under the template node texts. it won't show the error in smart form but while executing transaction out put could not issued.
Thanks,
Satheesh. -
Regarding recieving Plant in print preview of PO
Dear All,
We need to maintain address of delivery plant as default in print preview of PO for all vendors. Please guide how to customize.
Regards,
VikasHi,
In transaction NACE->ME-Purchasing->PO output types->Processing routine select the smart form and add the delivery plant fields with the help of ABAPER.
Regards,
BK -
Error IN ABAP PROGRAM AT PRINT PREVIEW
Dear All experts.
i got an error at gone to print preview of sales order delivery ALV reports. it gives an error follwing.
GETWA_NOT_ASSIGNED.
FIELD SYMBOL HAS BEEN NOT ASSIGNED.
BHAVESH PANCHALDear Expert.
thnks for reply.
Just check my code. Also check my output.
thnks
*& Report Z_SALES_EXP_BHAVESH
REPORT Z_SALES_EXP_BHAVESH.
TYPE-POOLS:slis.
TABLES
TABLES: vbep,
vbap,
vbpa,
vbkd,
vbak,
likp,
lips,
vbup,
vbbe,
konv,
kna1.
DATA :BEGIN OF itab OCCURS 0,
vbeln LIKE vbak-vbeln,
posnr LIKE vbap-posnr,
edatu LIKE vbep-edatu,
knumv LIKE vbak-knumv,
wmeng LIKE vbep-wmeng,
bmeng LIKE vbep-bmeng,
lfimg LIKE lips-lfimg,
omeng LIKE vbbe-omeng,
posar LIKE vbap-posar,
netwr LIKE vbap-netwr,
ntgew LIKE vbap-ntgew,
kbetr LIKE konv-kbetr,
kwert LIKE konv-kwert, " CONDITION VALUE.
kunnr LIKE vbak-kunnr,
name1 LIKE kna1-name1,
*BRGEW LIKE VBAP-BRGEW,
bstkd LIKE vbkd-bstkd,
bstdk LIKE vbkd-bstdk,
lfsta LIKE vbup-lfsta,
*KNUMV LIKE VBAK-KNUMV,
*posnr LIKE LIPS-POSNR,
*NETWR LIKE VBAK-NETWR,
brgew LIKE vbap-brgew,
LFMNG like vbap-LFMNG,
lfdat LIKE likp-lfdat,
*NTGEW LIKE LIKP-NTGEW,
delivery LIKE lips-vbeln,
*LFIMG LIKE LIPS-LFIMG,
KWMENG like VBAP-KWMENG,
op_qty like VBAP-KWMENG,
weight LIKE vbap-ntgew,
pending_val LIKE vbap-netwr,
END OF itab.
*variable for Report ID
DATA: v_repid LIKE sy-repid .
*declaration for fieldcatalog
DATA: i_fieldcat TYPE slis_t_fieldcat_alv,
wa_fieldcat TYPE slis_fieldcat_alv.
DATA: it_listheader TYPE slis_t_listheader.
declartion for layout
DATA: alv_layout TYPE slis_layout_alv.
*Title displayed when the alv list is displayed
*DATA: i_title_main TYPE lvc_title VALUE 'FIRST LIST DISPLAYED'.
DATA: i_title_main TYPE lvc_title VALUE 'Reports : Bhavesh Panchal'.
DATA : it_vbak TYPE vbak OCCURS 0 WITH HEADER LINE,
it_vbap TYPE vbap OCCURS 0 WITH HEADER LINE,
it_vbrk TYPE vbrk OCCURS 0 WITH HEADER LINE,
it_vbrp TYPE vbrp OCCURS 0 WITH HEADER LINE,
it_vbep TYPE vbep OCCURS 0 WITH HEADER LINE,
it_vbpa TYPE vbpa OCCURS 0 WITH HEADER LINE,
it_lips TYPE lips OCCURS 0 WITH HEADER LINE ,
it_likp TYPE likp OCCURS 0 WITH HEADER LINE,
it_konv TYPE konv OCCURS 0 WITH HEADER LINE,
it_kna1 TYPE kna1 OCCURS 0 WITH HEADER LINE,
it_adrc TYPE adrc OCCURS 0 WITH HEADER LINE,
it_makt TYPE makt OCCURS 0 WITH HEADER LINE,
it_mara TYPE mara OCCURS 0 WITH HEADER LINE,
it_vbkd TYPE vbkd OCCURS 0 WITH HEADER LINE,
it_vbbe TYPE vbbe OCCURS 0 WITH HEADER LINE,
it_vbup TYPE vbup OCCURS 0 WITH HEADER LINE,
it_itob TYPE itob OCCURS 0 WITH HEADER LINE.
INITIALIZATION.
v_repid = sy-repid.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
SELECT-OPTIONS : so_vbeln FOR vbak-vbeln ,
so_kunnr FOR vbpa-kunnr,
so_edatu FOR itab-edatu.
SELECTION-SCREEN: END OF BLOCK b1.
START-OF-SELECTION.
get the details required to be displayed in the report
PERFORM fetch_data.
*& End-of-Selection
END-OF-SELECTION.
IF itab[] IS NOT INITIAL.
initialize the fieldcatlog to be used for alv grid display
PERFORM field_catalog.
display actual data in the alv grid
PERFORM display.
ELSE.
initialize the fieldcatlog to be used for alv grid display
PERFORM field_catalog.
display actual data in the alv grid
PERFORM display.
ENDIF.
*& Form build_fieldcatlog
text
FORM field_catalog.
*- Show quoted text -
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'VBELN'.
wa_fieldcat-seltext_m = 'SalesOrderNo'.
wa_fieldcat-outputlen = '12'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field for Customer Name.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'NAME1'.
wa_fieldcat-seltext_m = 'Customer Name'.
wa_fieldcat-outputlen = '30'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For Po Number.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'BSTKD'.
wa_fieldcat-seltext_m = 'PO No'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For Order Value
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'NETWR'.
wa_fieldcat-seltext_m = 'Order Value '.
wa_fieldcat-outputlen = '12'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For Po Date.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'BSTDK'.
wa_fieldcat-seltext_m = 'PO Date'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'EDATU'.
wa_fieldcat-seltext_m = 'Delivery Date'.
wa_fieldcat-outputlen = '12'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For Order Qty.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'KWMENG'.
wa_fieldcat-seltext_m = 'Ord.QTY'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
field For Delivery Qty.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'op_qty'.
wa_fieldcat-seltext_m = 'DEL QTY.'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For Open Qty from ITAB.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'OMENG'.
wa_fieldcat-seltext_m = 'OPEN QTY.'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For Pending Weight from ITAB.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'BRGEW'.
wa_fieldcat-seltext_m = 'Pending Weight'.
wa_fieldcat-outputlen = '12'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For netweight.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'NTGEW'.
wa_fieldcat-seltext_m = 'Net Weight'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For Actual Delivery.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'LFDAT'.
wa_fieldcat-seltext_m = 'Actual Delivery'.
wa_fieldcat-outputlen = '12'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'KBETR'.
wa_fieldcat-seltext_m = 'RATE'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
wa_fieldcat-tabname = 'VBUP'.
wa_fieldcat-fieldname = 'LFSTA'.
wa_fieldcat-seltext_m = 'Delivery Status'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
Field For pending weight.
wa_fieldcat-tabname = 'ITAB'.
wa_fieldcat-fieldname = 'PENDING_VAL'.
wa_fieldcat-seltext_m = 'Pending VALUE'.
wa_fieldcat-outputlen = '20'.
APPEND wa_fieldcat TO i_fieldcat.
CLEAR wa_fieldcat.
ENDFORM. "BUILD_FIELDCATLOG
*& Form fetch_data
text
FORM fetch_data.
break mtabap.
SELECT *
FROM vbep
INTO TABLE it_vbep
WHERE edatu IN so_edatu
AND vbeln IN so_vbeln.
IF NOT it_vbep[] IS INITIAL.
SELECT *
FROM vbak
INTO TABLE it_vbak
FOR ALL ENTRIES IN it_vbep
WHERE vbeln = it_vbep-vbeln
AND kunnr IN so_kunnr.
ENDIF.
IF NOT it_vbak[] IS INITIAL.
SELECT *
FROM vbpa
INTO TABLE it_vbpa
FOR ALL ENTRIES IN it_vbak
WHERE vbeln = it_vbak-vbeln
AND posnr = space.
SELECT *
FROM vbap
INTO TABLE it_vbap
FOR ALL ENTRIES IN it_vbak
WHERE vbeln = it_vbak-vbeln.
Select all Customer Data
SELECT * FROM kna1 INTO TABLE it_kna1
FOR ALL ENTRIES IN it_vbak
WHERE kunnr = it_vbak-kunnr .
SELECT *
FROM vbkd
INTO TABLE it_vbkd
FOR ALL ENTRIES IN it_vbap
WHERE vbeln = it_vbap-vbeln.
and posnr = IT_VBAP-POSNR.
SELECT *
FROM vbbe
INTO TABLE it_vbbe
FOR ALL ENTRIES IN it_vbap
WHERE vbeln = it_vbap-vbeln
AND posnr = it_vbap-posnr.
SELECT *
FROM vbup
INTO TABLE it_vbup
FOR ALL ENTRIES IN it_vbap
WHERE vbeln = it_vbap-vbeln
AND posnr = it_vbap-posnr.
SELECT *
FROM konv
INTO TABLE it_konv
FOR ALL ENTRIES IN it_vbak
WHERE knumv = it_vbak-knumv
AND kinak = space .
SELECT *
FROM vbrp
INTO TABLE it_vbrp
FOR ALL ENTRIES IN it_vbak
WHERE aubel = it_vbak-vbeln.
IF NOT it_vbrp[] IS INITIAL.
SELECT * FROM likp
INTO TABLE it_likp
FOR ALL ENTRIES IN it_vbrp
WHERE vbeln = it_vbrp-vgbel.
SELECT * FROM lips
INTO TABLE it_lips
FOR ALL ENTRIES IN it_vbrp
WHERE vbeln = it_vbrp-vgbel
AND posnr = it_vbrp-vgpos.
itab-lfimg = it_lips-lfimg.
ENDIF. ENDIF.
LOOP AT it_vbap.
itab-posnr = it_vbap-posnr.
itab-posar = it_vbap-posar.
itab-brgew = it_vbap-brgew.
itab-ntgew = it_vbap-ntgew.
itab-KWMENG = it_vbap-kwmeng.
itab-LFMNG = it_vbap-LFMNG.
itab-LFIMG = it_lips-LFIMG.
itab-op_qty = it_vbap-kwmeng - it_lips-LFIMG.
READ TABLE it_vbak WITH KEY vbeln = it_vbap-vbeln.
itab-vbeln = it_vbak-vbeln.
itab-netwr = it_vbak-netwr.
itab-kunnr = it_vbak-kunnr.
READ TABLE it_vbep WITH KEY vbeln = it_vbap-vbeln.
itab-edatu = it_vbep-edatu.
READ TABLE it_kna1 WITH KEY kunnr = it_vbak-kunnr.
itab-name1 = it_kna1-name1.
READ TABLE it_vbkd WITH KEY vbeln = it_vbap-vbeln .
itab-bstdk = it_vbkd-bstdk.
itab-bstkd = it_vbkd-bstkd.
READ TABLE it_vbrp WITH KEY aubel = it_vbap-vbeln aupos = it_vbap-posnr.
READ TABLE it_lips WITH KEY vbeln = it_vbrp-aubel posnr = it_vbrp-aupos.
itab-delivery = it_lips-vbeln.
itab-del_qty = it_lips-lfimg.
itab-del_qty = LIPS-LFIMG.
READ TABLE it_likp WITH KEY vbeln = it_vbrp-aubel .
itab-lfdat = it_likp-lfdat.
itab-ntgew = it_likp-ntgew.
break mtabap.
READ TABLE it_vbup WITH KEY vbeln = it_vbap-vbeln posnr = it_vbap-posnr.
itab-lfsta = it_vbup-lfsta.
READ TABLE it_vbep WITH KEY vbeln = it_vbap-vbeln posnr = it_vbap-posnr.
itab-wmeng = it_vbap-kwmeng .
itab-bmeng = it_vbep-bmeng.
READ TABLE it_vbbe WITH KEY vbeln = it_vbap-vbeln posnr = it_vbap-posnr.
itab-omeng = it_vbbe-omeng .
READ TABLE it_konv WITH KEY knumv = it_vbak-knumv
kposn = it_vbap-posnr
kschl = 'PR00'.
ITAB-KBETR = IT_KONV-KBETR / 10. " CONDITION RATE
itab-kbetr = it_konv-kbetr.
itab-kwert = it_konv-kwert . "CONDITION VALUE
itab-pending_val = ITAB-OMENG * ITAB-KWERT .
itab-pending_val = itab-omeng * itab-kbetr .
APPEND itab.
ENDLOOP.
ENDFORM. "data_retrieval
*& Form build_listheader
text
-->IT_LISTHEADER text
Show quoted text -
FORM build_listheader USING it_listheader TYPE slis_t_listheader.
DATA HLINE TYPE SLIS_LISTHEADER.
DATA: ls_line TYPE slis_listheader.
bhavesh
HLINE-INFO = 'report Developed by Bhavesh'.
HLINE-TYP = 'H'.
Header
Bhavesh
CLEAR ls_line.
ls_line-typ = 'H'.
LS_LINE-KEY: not used for this type
ls_line-info = 'Sales ORDER Report'.
APPEND ls_line TO it_listheader.
bhavesh
***Selection
CLEAR ls_line.
ls_line-typ = 'S'.
ls_line-key = 'Key 1'.
ls_line-info = 'SFEL'.
APPEND ls_line TO it_listheader.
ls_line-key = 'Key 2'.
ls_line-info = 'SFEL'.
APPEND ls_line TO it_listheader.
***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 it_listheader.
ENDFORM. "BUILD_LISTHEADER
*ENDFORM. "build_listheader
*& Form display
*& text
FORM display.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = sy-repid
i_callback_top_of_page = 'TOP_OF_PAGE'
is_layout = alv_layout
it_fieldcat = i_fieldcat
it_events = gt_events[]
i_callback_user_command = 'USER_COMMAND'
i_grid_title = 'BHAVESH REPORT'
TABLES
t_outtab = itab[].
CLEAR : itab .
ENDFORM. "display
*& Form top_of_page
text
FORM top_of_page.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
it_list_commentary = it_listheader[].
i_logo = 'ENJOYSAP_LOGO'.
I_END_OF_LIST_GRID =
ENDFORM. "TOP_OF_PAGE -
Payment term in PO print preview different from PO header
We have set payment term ZI60 for vendor 2033803, but on the PO print preview it's "Payable immediately Due net" .In PO header (In delivery/invoice tab) also, it shows payment term to be ZI60...but on print preview it shows 'Payable immediately Due net' .What could be the reason?
"Payable immediately Due net" may be the description of payment term ZI60
goto to table TVZBT give ur payment term ZI60 and see the description......
i think
in the print program they have designed to display the description of payment term...if u want to display the payment term then ask ur ABAPer to change it... -
Converting Smartforms to PDF and displaying Smartforms on print preview
Hi,
How to convert smartforms to pdf?
How to attach this pdf to email?
How to attach this pdf to the email and at the same time can print preview the smartforms?
Thanks.Hi Navi,
Code Snippet for Simple Mail
*& Report ZZ_TEST *
REPORT zz_test .
INCLUDE zz_test_top.
INCLUDE zz_test01.
FORM entry *
--> RETURN_CODE *
--> US_SCREEN *
FORM entry USING return_code us_screen.
CLEAR retcode.
xscreen = us_screen.
PERFORM processing USING us_screen.
CASE retcode.
WHEN 0.
return_code = 0.
WHEN 3.
return_code = 3.
WHEN OTHERS.
return_code = 1.
ENDCASE.
ENDFORM. "entry
*& Include ZZ_TEST_TOP *
TABLES : nast,
tnapr.
TYPES : BEGIN OF t_SOUDNAMEI1.
INCLUDE STRUCTURE SOUDNAMEI1.
TYPES : END OF t_SOUDNAMEI1.
Internal Table declarations
DATA: i_otf TYPE itcoo OCCURS 0 WITH HEADER LINE,
i_tline TYPE TABLE OF tline WITH HEADER LINE,
i_receivers TYPE TABLE OF somlreci1 WITH HEADER LINE,
i_record LIKE solisti1 OCCURS 0 WITH HEADER LINE,
*Objects to send mail.
i_objpack LIKE sopcklsti1 OCCURS 0 WITH HEADER LINE,
i_objtxt LIKE solisti1 OCCURS 0 WITH HEADER LINE,
i_objbin LIKE solisti1 OCCURS 0 WITH HEADER LINE,
i_reclist LIKE somlreci1 OCCURS 0 WITH HEADER LINE,
i_lips LIKE lips OCCURS 0 WITH HEADER LINE,
i_SOUDNAMEI1 TYPE STANDARD TABLE OF t_SOUDNAMEI1.
Work Area declarations
DATA:w_objhead TYPE soli_tab,
wa_control_parameters TYPE ssfctrlop,
wa_output_options TYPE ssfcompop,
w_return TYPE ssfcrescl,
w_doc_chng TYPE sodocchgi1,
w_data TYPE sodocchgi1,
w_buffer TYPE string,"To convert from 132 to 255
wa_SOUDNAMEI1 TYPE t_SOUDNAMEI1,
Variables declarations
w_form_name TYPE rs38l_fnam,
w_len_in LIKE sood-objlen,
w_len_out LIKE sood-objlen,
w_len_outn TYPE i,
w_lines_txt TYPE i,
w_lines_bin TYPE i,
retcode TYPE sy-subrc,
xscreen TYPE c,
w_spld TYPE usr01-spld,
w_receiver TYPE SOXNA-FULLNAME,
w_OBJ_RECORD TYPE OBJ_RECORD,
w_user type sy-uname,
w_email TYPE ad_smtpadr.
Constants Declaration
CONSTANTS : c_x TYPE c VALUE 'X',
c_atrate(1) TYPE c VALUE '@'.
*& Include ZZ_TEST01 *
FORM PROCESSING *
FORM processing USING proc_screen.
SELECT * FROM lips
INTO TABLE i_lips
WHERE vbeln = nast-objky.
Call Function module to Getfunction Module name Generated by Smartform
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = tnapr-sform
IMPORTING
fm_name = w_form_name
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
IF sy-subrc <> 0.
retcode = sy-subrc.
ENDIF.
CLEAR : wa_control_parameters,
wa_output_options.
CASE nast-nacha.
WHEN '1'.
wa_control_parameters-device = 'PRINTER'.
WHEN '7'.
DATA: l_email TYPE ad_smtpadr.
wa_output_options-tdnoprev = c_x.
wa_control_parameters-getotf = c_x.
To get the default output device maintained in the
User profile
SELECT SINGLE spld FROM usr01
INTO w_spld
WHERE bname EQ nast-usnam.
IF sy-subrc EQ 0.
MOVE w_spld TO wa_output_options-tddest .
ENDIF.
wa_output_options-tdnoprev = c_x.
wa_control_parameters-getotf = c_x.
To get the email address maintained for the particular output
CALL FUNCTION 'NAST_GET_MESSAGE_OBJECT_RECV'
EXPORTING
pi_objkey = nast-tdname
IMPORTING
pe_addr = w_receiver
CHANGING
pc_objhandle = w_obj_record
EXCEPTIONS
maildata_not_readable = 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.
IF w_receiver NA c_atrate.
To retrieve the E-Mail Id in case we get the User name from NAST
CLEAR wa_soudnamei1.
REFRESH i_soudnamei1.
MOVE w_receiver TO wa_soudnamei1-fullname.
To get the user name
CALL FUNCTION 'SO_NAME_CONVERT_API1'
EXPORTING
name = wa_soudnamei1
TABLES
names = i_soudnamei1
EXCEPTIONS
user_not_exist = 1
parameter_error = 2
x_error = 3
OTHERS = 4.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
CLEAR wa_soudnamei1.
READ TABLE i_soudnamei1 INTO wa_soudnamei1 INDEX 1.
MOVE wa_soudnamei1-sapname TO w_user.
To get the e-mail Id maintained in the user profile
CALL FUNCTION 'FTR_CORR_CHECK_EMAIL_SAP_USER'
EXPORTING
i_user = w_user
IMPORTING
e_email_address = l_email
EXCEPTIONS
mail_address = 1
determination_error = 2
OTHERS = 3.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
MOVE l_email TO w_receiver.
ENDIF.
MOVE w_receiver TO w_email.
ENDCASE.
wa_control_parameters-no_dialog = c_x.
wa_control_parameters-langu = nast-spras .
wa_output_options-tdteleland = nast-tland.
wa_output_options-tdtelenum = nast-telfx .
wa_output_options-tdsenddate = nast-erdat .
wa_output_options-tdsendtime = nast-eruhr .
wa_output_options-tddataset = nast-dsnam .
wa_output_options-tdsuffix1 = nast-dsuf1 .
wa_output_options-tdsuffix2 = nast-dsuf2 .
wa_output_options-tdimmed = nast-dimme .
wa_output_options-tddelete = nast-delet .
wa_output_options-tdautority = nast-tdautority.
wa_output_options-tdcovtitle = nast-tdcovtitle .
wa_output_options-tdcover = nast-tdocover .
wa_output_options-tdreceiver = nast-tdreceiver.
wa_output_options-tddivision = nast-tddivision.
wa_output_options-tdcopies = nast-anzal .
wa_output_options-tdnewid = c_x.
wa_output_options-tdarmod = nast-tdarmod.
wa_output_options-tdnoarmch = c_x.
CALL FUNCTION w_form_name
EXPORTING
archive_index = toa_dara
archive_parameters = arc_params
control_parameters = wa_control_parameters
output_options = wa_output_options
user_settings = ' '
IMPORTING
job_output_info = w_return
TABLES
it_lips = i_lips
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF nast-nacha EQ 7 AND sy-subrc EQ 0.
i_otf[] = w_return-otfdata[].
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
format = 'PDF'
max_linewidth = 132
IMPORTING
bin_filesize = w_len_in
TABLES
otf = i_otf
lines = i_tline
EXCEPTIONS
err_max_linewidth = 1
err_format = 2
err_conv_not_possible = 3
OTHERS = 4.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
Convert PDF from 132 to 255.
LOOP AT i_tline.
Replacing space by ~
TRANSLATE i_tline USING ' ~'.
CONCATENATE w_buffer i_tline INTO w_buffer.
ENDLOOP.
Replacing ~ by space
TRANSLATE w_buffer USING '~ '.
DO.
i_record = w_buffer.
Appending 255 characters as a record
APPEND i_record.
SHIFT w_buffer LEFT BY 255 PLACES.
IF w_buffer IS INITIAL.
EXIT.
ENDIF.
ENDDO.
REFRESH: i_reclist,
i_objtxt,
i_objbin,
i_objpack.
CLEAR w_objhead.
Object with PDF.
i_objbin[] = i_record[].
DESCRIBE TABLE i_objbin LINES w_lines_bin.
Document information.
w_doc_chng-obj_name = 'Smartform'.
w_doc_chng-expiry_dat = sy-datum + 10.
CONCATENATE 'Delivery' 'Note'
INTO w_doc_chng-obj_descr.
*w_doc_chng-obj_descr = 'Smart form output'.
w_doc_chng-sensitivty = 'F'. "Functional object
w_doc_chng-doc_size = w_lines_txt * 255.
Pack to main body as RAW.
Obj. to be transported not in binary form
CLEAR i_objpack-transf_bin.
Start line of object header in transport packet
i_objpack-head_start = 1.
Number of lines of an object header in object packet
i_objpack-head_num = 0.
Start line of object contents in an object packet
i_objpack-body_start = 1.
Number of lines of the object contents in an object packet
i_objpack-body_num = w_lines_txt.
Code for document class
i_objpack-doc_type = 'RAW'.
APPEND i_objpack.
Packing as PDF.
i_objpack-transf_bin = 'X'.
i_objpack-head_start = 1.
i_objpack-head_num = 1.
i_objpack-body_start = 1.
i_objpack-body_num = w_lines_bin.
i_objpack-doc_type = 'PDF'.
i_objpack-obj_name = 'Smartform'.
CONCATENATE 'Delivery' 'Note' '.pdf'
INTO i_objpack-obj_descr.
i_objpack-doc_size = w_lines_bin * 255.
APPEND i_objpack.
Document information.
CLEAR i_reclist.
e-mail receivers.
i_reclist-receiver = w_email.
i_reclist-express = 'X'.
i_reclist-rec_type = 'U'. "Internet address
APPEND i_reclist.
sending mail.
CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
EXPORTING
document_data = w_doc_chng
put_in_outbox = 'X'
TABLES
packing_list = i_objpack
object_header = w_objhead
contents_bin = i_objbin
contents_txt = i_objtxt
receivers = i_reclist
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
document_type_not_exist = 3
operation_no_authorization = 4
parameter_error = 5
x_error = 6
enqueue_error = 7
OTHERS = 8.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDIF.
ENDFORM. "processing
OTF to PDF
========================================================================
Program1
*& REPORT zpmm_print1
REPORT zpmm_print1.
DATA : gw_ssfcrescl TYPE ssfcrescl.
DATA: gt_otf TYPE STANDARD TABLE OF itcoo ,
gt_tline TYPE STANDARD TABLE OF tline,
gv_len LIKE sood-objlen,
gw_ssfctrlop TYPE ssfctrlop, "for CONTROL_PARAMETERS
gw_ssfcompop TYPE ssfcompop. "for OUTPUT_OPTIONS
DATA fm_name TYPE rs38l_fnam.
gw_ssfctrlop-getotf = 'X'.
gw_ssfctrlop-no_dialog = 'X'.
gw_ssfcompop-tdnoprev = 'X'.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = 'ZPMM_1'
IMPORTING
fm_name = fm_name
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
IF sy-subrc <> 0.
<error handling>
ENDIF.
CALL FUNCTION fm_name
EXPORTING
ARCHIVE_INDEX =
ARCHIVE_INDEX_TAB =
ARCHIVE_PARAMETERS =
control_parameters = gw_ssfctrlop
MAIL_APPL_OBJ =
MAIL_RECIPIENT =
MAIL_SENDER =
output_options = gw_ssfcompop
user_settings = 'X'
IMPORTING
DOCUMENT_OUTPUT_INFO =
job_output_info = gw_ssfcrescl
JOB_OUTPUT_OPTIONS =
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
gt_otf[] = gw_ssfcrescl-otfdata[].
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
format = 'PDF'
max_linewidth = 132
IMPORTING
bin_filesize = gv_len
TABLES
otf = gt_otf
lines = gt_tline
EXCEPTIONS
err_max_linewidth = 1
err_format = 2
err_conv_not_possible = 3
OTHERS = 4.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
DATA : gv_filename LIKE rlgrap-filename VALUE 'C:\swet.pdf'.
CALL FUNCTION 'DOWNLOAD'
EXPORTING
bin_filesize = gv_len
filename = gv_filename
filetype = 'BIN'
filetype_no_show = 'X'
IMPORTING
act_filename = gv_filename
filesize = gv_len
cancel = ''
TABLES
data_tab = gt_tline.
Program 2
*& REPORT zpmm_print2
REPORT zpmm_print2.
DATA : gw_ssfcrescl TYPE ssfcrescl.
DATA: gt_otf TYPE STANDARD TABLE OF itcoo ,
gt_tline TYPE STANDARD TABLE OF tline,
gv_len LIKE sood-objlen,
gw_ssfctrlop TYPE ssfctrlop, "for CONTROL_PARAMETERS
gw_ssfcompop TYPE ssfcompop. "for OUTPUT_OPTIONS
DATA fm_name TYPE rs38l_fnam.
gw_ssfctrlop-getotf = 'X'.
gw_ssfctrlop-no_dialog = 'X'.
gw_ssfcompop-tdnoprev = 'X'.
CALL FUNCTION '/1BCDWB/SF00000041'
EXPORTING
ARCHIVE_INDEX =
ARCHIVE_INDEX_TAB =
ARCHIVE_PARAMETERS =
control_parameters = gw_ssfctrlop
MAIL_APPL_OBJ =
MAIL_RECIPIENT =
MAIL_SENDER =
output_options = gw_ssfcompop
user_settings = 'X'
IMPORTING
DOCUMENT_OUTPUT_INFO =
job_output_info = gw_ssfcrescl
JOB_OUTPUT_OPTIONS =
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
gt_otf[] = gw_ssfcrescl-otfdata[].
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
format = 'PDF'
max_linewidth = 132
IMPORTING
bin_filesize = gv_len
TABLES
otf = gt_otf
lines = gt_tline
EXCEPTIONS
err_max_linewidth = 1
err_format = 2
err_conv_not_possible = 3
OTHERS = 4.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
DATA : gv_filename LIKE rlgrap-filename VALUE 'C:\swet.pdf'.
CALL FUNCTION 'DOWNLOAD'
EXPORTING
bin_filesize = gv_len
filename = gv_filename
filetype = 'BIN'
filetype_no_show = 'X'
IMPORTING
act_filename = gv_filename
filesize = gv_len
cancel = ''
TABLES
data_tab = gt_tline.
=========================================================================
Cheers
Mohinder Singh Chauhan -
PDF print preview not coming as it contains chinese character
hi
when i see the print preview of the Delivery note ( in scripts ) normally, the chinese characters appears. but when i want to check with pdf print preview nothing is coming.
i am using convert_otf func. module.
is it because of function module or because of adobe acrobat?
also when i try to print the ordinary print preview - output is coming as ####.
My advance thanks for your replies.
Regards,
Sakthi Sri.Hi Sandra Rossi,
In PDF i could not able to get the output. So discussed with TL and we made the chinese characters in .tiff and uploaded through se78 and now it is coming in ordinary print preview.
but this is only temporary solution.
Anyhow thanks for help given by experts.
Maybe you are looking for
-
Not able to attach a clause document in SAP E-sourcing
When I try to attach a clause document while creating a clause a error message is displayed saying: 'There is a problem with Cotract Generation web service. Contact your system Administrator' Any idea on how this can be resolved?
-
Beware of Zoomify and Flash CS3!
Does anyone else have problems getting Zoomifyer for Flash to work in Flash CS3 on Mac OSX? Everytime I launch the Component Inspector in the Zoomify Viewer Component I get an alert saying: "Reference Error ZoomifyFileAPI is not defined". This is one
-
I can not get my magic mouse to work in bootcamp...
I have a Macbook and I bought a Magic Mouse and I can not get it to Sync with my Laptop in Boot Camp. I am running window 7 ultimate and would like to use one Mouse for this computer.
-
Cannot install iTunes 11.4 on xp sp3, no error messages
I couldn't install the latest iTunes on xp sp3 laptop. Installation went fine and no error message, but iTunes is not installed while Bonjour and other components are installed. There is no iTunes folder in program files. This is baffling. Does anyon
-
Hi, I am trying to download the payment file generated to my presentation server. This file is generated for Greece company code and has the vendor name in greek language. When downloading it gives me an error that "Individual characters could not be