Smartform PO Print outs
Hi,
I am new to smartforms.i want to develop smartform for PO print out can anybody help?
Moderator message: sorry, these forums cannot replace proper training, please search for available documentation or attend classes.
Edited by: Thomas Zloch on Nov 25, 2010 10:48 AM
hai freind,
please go through sap technical ok.
thanks ,
anji.
Moderator message: please do not reply to such questions, you have been warned many times, I will very soon suggest your ID for deletion if you don't change your behaviour.
Edited by: Thomas Zloch on Nov 25, 2010 10:49 AM
Similar Messages
-
Smartform prints out Black boxes instead of Shade
Hello Experts,
I have developed some smartforms which have some boxes that are shaded with grey color for heading.
They work fine for some existing printers. But when i issue a print out on a new printer i
see that the shaded boxes are displayed as solid black boxes on the print out.
I also tried to print it in color but invain. Even the LOGO also got blacked out.
Can any one suggest me what to do.
Is it with my smartform or printer settings. Please advice.
Thanks
DanyHi
I don't know if u can't find out a solution.
All device output (printers) having the same divice type have the same behavior, i.e. printers having a different device type can give a different output, so if u'll correct the problem for a certain group of printers u could have a new problem for other group.
I think the best soltion is to use the printer used to test the smartforms
Max -
Font in print out of smartform
Hi All,
I have uploaded a font and it is maintained in both Font & Printer Family. I have created a STYLE for the font and using the same in my Smartform.
When i see the preview of the Smartform, the font is displayed large + Bold ( as per our requirement).
But when i take a print out, a small size font is printed.
Any pointers for the same would be helpful.
Ps. : The font is printed correctly when logged on with EN language but when logged on with JA language then it doesnt print correctly though it displays correctly in print preview.
Best regards,
PrashantHi,
The settings mentioned by Kishan are already in place. Still it doesnt give the desired output.
Also, this is a new Form created in English language.
I have tried the existing fonts as well as uploading fonts, but still no +ve results.
Also, could someone please explain, why the font through STYLE can be entered only of max size 99.00. But in PRINTER the font for 120,160 is also maintained.
Thanks,
Best regards,
Prashant -
Could u tell me how2control printing out the certain page in smartforms?
there are many pages when I preview ,
but I only need one or several of the pages.
How to print the certain page in smartforms?
and if there are several windows in one page
how can I just print out one or several windows of them?
what should I insert "command" or "program lines" into
the "flow logic" ?
It's very kind of you to explain that in detail.
Thanks very much in advance.pls help me,thank you
-
Smartform print out problem : urgent
Hi,
I have developed a smartform to take the printout of the Sales Order created in VA01.
I am facing a problem while taking the printout only if the line item in the sales order are more than 25.
I the line items are less than 25 then I am able to see to the print preview as well as able to take the print out but if the item are more than 25 then I am not able to see the preview also and even able to take the print.
Kindly anybody suggest
Regards,
shyam,hi shyam..
Remember one thing u <b>always give the first page--> next page will ber first page only.. in u r requirement</b> (because in the firtst u r printing the item details, who knows there colud be chances of items may not fit in 1 page so when the items are more it will give proble if u give the first page next page is second page)
do as follows-- you have 2 pages PAGE1(first page) PAGE2)second Page).. now
1..in PAGE1's give the next page as PAGE1, in the PAGE2 give the next page as PAGE2.
2.. After competion of printing the ITEM details u need to print the ITEM COnditions.. so we will trigger the second page explicitily by using the COMMAND after completion of first page..
for this--> at end of the main window <b>right clice > create>flow logi-->command</b>.
now command widow will be inserted.. in this tick the GOTO NEXT PAGE :inthis give PAGE2. in condition tab of the COMMAND "tick only after end of Main Window.
Please wite if u r proble m is not solved..
Please Close this thread.. when u r problem is solved
Reward if Helpful
Regards
Naresh Reddy K -
How to avoid that every page of a smartform is going to be printed out
Hi,
I have following problem. In my smartform I builded different pages (like a cover page, different lists etc.). The user should decide by setting parameters what lists he want to print. So if he don´t need the cover page, it should not be printed out.
Is there any way to set this up in the smartform? Right now, the printing parameters (what the user wants to print) are stored in an internal table and should be processed in the smartform. My problem is that there is no way to implement conditions on a page in a smartform.
Please let me know if somebody has a solution for this requirement.
Thanks a lot,
John Caspar
<MOVED TO CORRECT FORUM BY MODERATOR>
Edited by: Alvaro Tejada Galindo on Apr 15, 2009 8:49 AMHi Micky,
The external debugging works. Thank you very much!
And how can I reward you? -
Payment term not appearing in PO print out
Hello all,
We have one PO where Payment term is not appearing in PO print out. I have checked other POs of the same type where its appearing in print out. In PO header payment term is maintained. Does this flow from Vendor mastre?
RegardsHi,
Is this payment term is new one !
Yes, payment term should flow from vendor master to PO.
Now as payment term not printed in PO print, just check with your PO output type & related FORM or PDF/SmartForm in it for application EF in NACE t.code. Also check SmartForm in t.code: SMARTFORMS . Or if FORM check in t.code:SE71 / SE73 the SapScript & see inclusion of all payment term in it with help of with ABAP consultant.
Regards,
Biju K -
Problem report only print out when i click back button
hi all..i having problem with my report print program. the problem is my report did not immediately print out when i click print button. the program require me to click back button before print out execute. please help me to solve this problem. Thank you.
Edited by: padile on Jan 7, 2010 3:51 AMHi,
In your program, mention the following:
DATA: gs_out_opt TYPE ssfcompop.
gs_out_opt-tdimmed = 'X' "Print immediately
CALL FUNCTION lv_fname "Smartform FM
EXPORTING
output_options = gs_out_opt
Regards,
Dawood. -
Error in smartform when printing multiple pages
Hi,
I m using a smartform which have two pages in it,
i m able to save and activate it without any error message and when i run the function module generated to chk my smartform
it runs fine and diplays two pages i m using.
but as i m attaching this form with my driver program it is giving an error message while running . the error message is " No other output defined in main window."
Please help me out to resolve the issue.Re: error in smartform when printing multiple pages
dharani tadikonda
Thanks for this answer. It is absolutely correct. -
Dear All.
Till this day the duty-form for a company were performed through a
special Form Program, it is performed via processing routines.
The first Form Routine's name is entry.
Form was printed-out for each Transport up to now.
Current Requirements are for next time as follows:
Printing out one form for every delivery (shipment) instead of
for each Transport as so far. Please notice one Transport may
consist of many deliveries (Shipment). 1 Transport : n Shipment.
DATA:
lc_wa_usrdata TYPE /Z2a/ty_lw_usrdata.
INCLUDE rvadtabl.
SET EXTENDED CHECK OFF.
TABLES: vbpla, thead, ttxer, ttxit, t005, vbddl, stxh, sadr."SADR40A
INCLUDE vttkdata. "Shipment Header
INCLUDE vttsdata. "Shipment Segment
INCLUDE vttpdata. "Shipment Items
INCLUDE vbpadata. "Partner
INCLUDE vtfadata. "Flow
INCLUDE sadrdata. "Address
INCLUDE vtlfdata. "Delivery Selection
INCLUDE vsedata. "shipping units
INCLUDE rv56acom. "I/O-Structure
SET EXTENDED CHECK ON.
TABLES: /Z2a/tv_schein.
FORM entry USING return_code us_screen.
DATA: lf_retcode TYPE sy-subrc.
screen = us_screen.
PERFORM processing USING us_screen
CHANGING lf_retcode.
IF lf_retcode NE 0.
return_code = 1.
ELSE.
return_code = 0.
ENDIF.
ENDFORM.
FORM processing USING proc_screen
CHANGING cf_retcode.
DATA: ls_print_data_to_read TYPE ledlv_print_data_to_read.
DATA: ls_dlv_delnote TYPE ledlv_delnote.
DATA: lf_fm_name TYPE rs38l_fnam.
DATA: ls_control_param TYPE ssfctrlop.
DATA: ls_composer_param TYPE ssfcompop.
DATA: ls_recipient TYPE swotobjid.
DATA: ls_sender TYPE swotobjid.
DATA: lf_formname TYPE tdsfname.
DATA: ls_addr_key LIKE addr_key.
DATA: ls_header LIKE /Z2a/ss_pv_kopf.
DATA: tb_daten LIKE /Z2a/ss_pv_daten OCCURS 1.
DATA: lc_va_lfnr TYPE nrlevel.
DATA: lc_va_year TYPE char4.
DATA: lc_va_keyseg_pv TYPE /dca/p000_keyseg.
DATA: lc_tb_bwdat_pv TYPE /dca/p000_ty_tb_bwdat.
DATA: lc_wa_bwdat_pv TYPE /dca/p000_ty_wa_bwdat.
DATA: lc_wa_bwm_res_pv TYPE /Z2a/dat_cu_pvschein.
DATA: lc_va_lifnr TYPE kunnr.
DATA: lc_va_nr TYPE nrnr.
DATA: lc_va_anz TYPE /Z2a/anz_pv.
DATA: lc_va_no TYPE /Z2a/anz_kein_pv.
DATA: lc_wa_pvschein LIKE /Z2a/tv_schein.
DATA: lc_va_line LIKE sy-tabix.
DATA: lc_va_flag_zoll TYPE segal,
lc_va_rqident TYPE rspoid,
lc_va_vsart TYPE vsarttr,
lc_va_tknum TYPE tknum.
DATA: lc_va_obj TYPE nrobj.
DATA: lc_va_printer TYPE rspopname.
DATA: lc_va_pv_kz TYPE char4.
DATA: lc_va_tplst TYPE tplst.
* SmartForm from customizing table TNAPR
lf_formname = tnapr-sform.
* determine print data
PERFORM set_print_data_to_read USING lf_formname
CHANGING ls_print_data_to_read
cf_retcode.
IF cf_retcode = 0.
* select print data
PERFORM get_data_pv TABLES tb_daten
CHANGING ls_header
lc_va_flag_zoll
lc_va_vsart
lc_va_tplst
cf_retcode.
ENDIF.
lc_va_tknum = nast-objky.
IF cf_retcode = 0.
ELSE.
PERFORM protocol_nast_update.
cf_retcode = 4.
EXIT.
ENDIF.
IF cf_retcode = 0.
* determine smartform function module for delivery note
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING formname = lf_formname
IMPORTING fm_name = lf_fm_name
EXCEPTIONS no_form = 1
no_function_module = 2
OTHERS = 3.
IF sy-subrc <> 0.
ENDIF.
ENDIF.
DESCRIBE TABLE tb_daten LINES lc_va_line.
IF lc_va_line <> 0.
lc_va_pv_kz = 'JA'.
SELECT SINGLE lifnr
FROM vtpa
INTO lc_va_lifnr
WHERE vbeln = nast-objky
AND parvw = 'YL'.
lc_va_keyseg_pv = ls_header-kunnr.
lc_va_keyseg_pv+10(10) = lc_va_lifnr.
lc_va_keyseg_pv+20(2) = lc_va_vsart.
lc_va_keyseg_pv+22(4) = lc_va_pv_kz.
CALL FUNCTION '/ZTR/P000_MCDATA_FROM_'
EXPORTING
cv_va_keytyp = '/Z2a/KEY_CU_PVSCHEIN'
cv_va_keyseg = lc_va_keyseg_pv
TABLES
cr_tb_bwdat = lc_tb_bwdat_pv.
IF lc_tb_bwdat_pv[] IS INITIAL.
cf_retcode = 4.
ELSE.
LOOP AT lc_tb_bwdat_pv INTO lc_wa_bwdat_pv.
lc_wa_bwm_res_pv = lc_wa_bwdat_pv-datseg.
lc_va_obj = lc_wa_bwm_res_pv(10).
lc_va_nr = lc_wa_bwm_res_pv+10(2).
lc_va_anz = lc_wa_bwm_res_pv+12(8).
lc_va_printer = lc_wa_bwm_res_pv+20(4).
SELECT SINGLE pvno
FROM /Z2a/tv_schein
INTO lc_va_lfnr
WHERE tknum = nast-objky.
IF sy-subrc = 0.
ELSE.
CALL FUNCTION 'NUMBER_GET_NEXT'
EXPORTING
nr_range_nr = lc_va_nr
object = lc_va_obj
IMPORTING
number = lc_va_lfnr
IF sy-subrc <> 0.
ENDIF.
ENDIF.
ENDLOOP.
ENDIF.
* call smartform delivery note
ls_composer_param-tddest = lc_va_printer.
* ls_control_param-device = lc_va_printer.
lc_va_year = sy-datum(4).
PERFORM set_print_param USING ls_addr_key
lc_va_lfnr
CHANGING ls_control_param
ls_composer_param
ls_recipient
ls_sender
cf_retcode.
lc_wa_usrdata-mandt = sy-mandt.
lc_wa_usrdata-udate = sy-datum.
lc_wa_usrdata-uzeit = sy-uzeit.
lc_wa_usrdata-usr = sy-uname.
lc_wa_usrdata-sysid = sy-sysid.
DO lc_va_anz TIMES.
CALL FUNCTION lf_fm_name
EXPORTING
archive_index = toa_dara
archive_parameters = arc_params
control_parameters = ls_control_param
mail_recipient = ls_recipient
mail_sender = ls_sender
output_options = ls_composer_param
user_settings = ' '
ls_header = ls_header
lc_va_lfnr = lc_va_lfnr
lc_va_year = lc_va_year
lc_va_tplst = lc_va_tplst
lc_wa_usrdata = lc_wa_usrdata
TABLES
tb_daten = tb_daten
EXCEPTIONS formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF sy-subrc <> 0.
ENDIF.
ENDDO.
ELSE.
lc_va_pv_kz = 'NEIN'.
SELECT SINGLE lifnr
FROM vtpa
INTO lc_va_lifnr
WHERE vbeln = nast-objky
AND parvw = 'YL'.
lc_va_keyseg_pv = ls_header-kunnr.
lc_va_keyseg_pv+10(10) = lc_va_lifnr.
lc_va_keyseg_pv+20(2) = lc_va_vsart.
lc_va_keyseg_pv+22(4) = lc_va_pv_kz.
CALL FUNCTION '/ZTR/P000_MCDATA_FROM_'
EXPORTING
cv_va_keytyp = '/Z2a/KEY_CU_PVSCHEIN'
cv_va_keyseg = lc_va_keyseg_pv
TABLES
cr_tb_bwdat = lc_tb_bwdat_pv.
IF lc_tb_bwdat_pv[] IS INITIAL.
cf_retcode = 4.
ELSE.
LOOP AT lc_tb_bwdat_pv INTO lc_wa_bwdat_pv.
lc_wa_bwm_res_pv = lc_wa_bwdat_pv-datseg.
lc_va_obj = lc_wa_bwm_res_pv(10).
lc_va_nr = lc_wa_bwm_res_pv+10(2).
lc_va_anz = lc_wa_bwm_res_pv+12(8).
lc_va_printer = lc_wa_bwm_res_pv+20(4).
SELECT SINGLE pvno
FROM /Z2a/tv_schein
INTO lc_va_lfnr
WHERE tknum = nast-objky.
IF sy-subrc = 0.
UPDATE /Z2a/tv_schein
SET flag_pv = ' '
WHERE tknum = nast-objky.
ELSE.
* laufende nummer füllen, bei keinen PV-Teilen Nummernkreis 99
CALL FUNCTION 'NUMBER_GET_NEXT'
EXPORTING
nr_range_nr = lc_va_nr
object = lc_va_obj
* QUANTITY = '1'
* SUBOBJECT = ' '
* TOYEAR = '0000'
* IGNORE_BUFFER = ' '
IMPORTING
number = lc_va_lfnr
* QUANTITY =
* RETURNCODE =
* EXCEPTIONS
* INTERVAL_NOT_FOUND = 1
* NUMBER_RANGE_NOT_INTERN = 2
* OBJECT_NOT_FOUND = 3
* QUANTITY_IS_0 = 4
* QUANTITY_IS_NOT_1 = 5
* INTERVAL_OVERFLOW = 6
* BUFFER_OVERFLOW = 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.
ENDLOOP.
lc_va_year = sy-datum(4).
ls_composer_param-tddest = lc_va_printer.
PERFORM set_print_param USING ls_addr_key
lc_va_lfnr
CHANGING ls_control_param
ls_composer_param
ls_recipient
ls_sender
cf_retcode.
lc_wa_usrdata-mandt = sy-mandt.
lc_wa_usrdata-udate = sy-datum.
lc_wa_usrdata-uzeit = sy-uzeit.
lc_wa_usrdata-usr = sy-uname.
lc_wa_usrdata-sysid = sy-sysid.
DO lc_va_anz TIMES.
CALL FUNCTION lf_fm_name
EXPORTING
archive_index = toa_dara
archive_parameters = arc_params
control_parameters = ls_control_param
mail_recipient = ls_recipient
mail_sender = ls_sender
output_options = ls_composer_param
user_settings = ' '
ls_header = ls_header
lc_va_lfnr = lc_va_lfnr
lc_va_year = lc_va_year
lc_va_tplst = lc_va_tplst
lc_wa_usrdata = lc_wa_usrdata
TABLES
tb_daten = tb_daten
EXCEPTIONS formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF sy-subrc <> 0.
ENDIF.
ENDDO.
ENDIF.
ENDIF.
SELECT SINGLE *
FROM /Z2a/tv_schein
INTO lc_wa_pvschein
WHERE tknum = nast-objky.
IF sy-subrc = 0.
ELSE.
IF NOT lc_va_lfnr IS INITIAL.
lc_wa_pvschein-mandt = sy-mandt.
lc_wa_pvschein-tknum = nast-objky.
INSERT INTO /Z2a/tv_schein
VALUES lc_wa_pvschein.
UPDATE /Z2a/tv_schein SET
pvno = lc_va_lfnr
vsart = lc_va_vsart
exti1 = ls_header-schiffname
signi = ls_header-siegel
flag_zoll = lc_va_flag_zoll
exti2 = ls_header-contnr
lifex = ls_header-mbcnr
dalen = ls_header-dalen
dptbg = ls_header-dptbg
kunnr = ls_header-kunnr
add03 = ls_header-add03
parnr = lc_va_lifnr
datum_druck = sy-datum
uzeit_druck = sy-uzeit
ernam_druck = sy-ucomm
WHERE tknum = nast-objky.
IF tb_daten IS INITIAL.
UPDATE /Z2a/tv_schein SET
flag_pv = ' '
WHERE tknum = nast-objky.
ELSE.
UPDATE /Z2a/tv_schein SET
flag_pv = 'X'.
ENDIF.
ENDIF.
ENDIF.
* get SmartForm protocoll and store it in the NAST protocoll
* PERFORM ADD_SMFRM_PROT. DEL_HP_335958
ENDFORM.
FORM get_data_pv TABLES lc_tb_daten
CHANGING cs_header TYPE /Z2a/ss_pv_kopf
lc_va_flag_zoll TYPE segal
lc_va_vsart TYPE vsarttr
lc_va_tplst TYPE tplst
cf_retcode.
TYPES: BEGIN OF ty_wa_vbeln,
vbeln TYPE vbeln_vl,
END OF ty_wa_vbeln,
ty_tb_vbeln TYPE STANDARD TABLE OF ty_wa_vbeln
WITH DEFAULT KEY
INITIAL SIZE 0,
ty_wa_lips LIKE lips,
ty_tb_lips TYPE STANDARD TABLE OF ty_wa_lips
WITH DEFAULT KEY
INITIAL SIZE 0.
DATA: lc_tb_cond LIKE /Z2a/ss_pv_daten OCCURS 1.
DATA: lc_wa_daten TYPE /Z2a/ss_pv_daten.
DATA: lc_wa_cond TYPE /Z2a/ss_pv_daten.
DATA: lc_va_tknum TYPE tknum,
lc_tb_lips TYPE ty_tb_lips,
lc_wa_lips TYPE ty_wa_lips,
lc_va_kunnr TYPE kunnr,
lc_va_pvvkz TYPE /Z2a/pvvkz,
lc_va_exprf TYPE exprf,
lc_va_matnr TYPE matnr,
lc_va_menge TYPE lfimg.
DATA: lc_tb_vbeln TYPE ty_tb_vbeln,
lc_wa_vbeln TYPE ty_wa_vbeln,
lc_va_land1 TYPE land1,
lc_va_lifnr TYPE lifnr.
DATA: lc_va_exnum TYPE exnum.
DATA: lc_va_keyseg TYPE /dca/p000_keyseg.
DATA: lc_tb_bwdat TYPE /dca/p000_ty_tb_bwdat.
DATA: lc_wa_bwdat TYPE /dca/p000_ty_wa_bwdat.
DATA: lc_wa_bwm_result TYPE /Z2a/dat_cu_pvabwicklung.
DATA language LIKE nast-spras.
DATA shipment_number LIKE vttk-tknum.
CLEAR cf_retcode.
* get data
language = nast-spras.
shipment_number = nast-objky.
CALL FUNCTION 'RV_SHIPMENT_PRINT_VIEW'
EXPORTING
shipment_number = shipment_number
option_tvtk = 'X' "Shipmenttype J/N
option_ttds = 'X' "Disposition J/N
language = language
option_items = 'X' "Transport Items J/N
option_segments = 'X' "Transport Segments J/N
option_partners = 'X' "Partners J/N
option_sales_orders = 'X' "Sales orders J/N
option_export_data = 'X' "Export data J/N
option_packages = 'X' "Packages J/N
option_flow = ' ' "Flow J/N
option_no_refresh = ' ' "Refresh Tables J/N
IMPORTING
f_vttkvb = vttkvb "Shipment Header
f_tvtk = tvtk "Shipmenttype
f_tvtkt = tvtkt "Description Shipmenttype
f_ttds = ttds "Disposition
f_ttdst = ttdst "Description Disposition
f_vbpla = vbpla "Packages
TABLES
f_vttp = xvttp "Shipment Items
f_trlk = slk "Delivery
f_trlp = slp "Delivery Item
f_vtts = xvtts "Shipment Segments
f_vtsp = xvtsp "Segments/Items
f_vbpa = xvbpa "Partner
f_vbadr = xvbadr "Address
f_vtfa = xvtfa "Flow
f_vbplk = xvbplk "Shipment Unit Header
f_vbplp = xvbplp "Shipment Unit
f_vbpls = xvbpls "Shipment Unit Sum
EXCEPTIONS
not_found = 1.
cs_header-tknum = nast-objky.
cs_header-schiffname = vttkvb-exti1.
cs_header-abfahrt = vttkvb-dptbg.
cs_header-contnr = vttkvb-exti2.
cs_header-normt = vttkvb-add01.
cs_header-siegel = vttkvb-signi.
cs_header-gewbr = vttkvb-text2.
cs_header-gewnt = vttkvb-text3.
cs_header-dalen = vttkvb-dalen.
cs_header-dptbg = vttkvb-dptbg.
cs_header-add03 = vttkvb-add03.
lc_va_tplst = vttkvb-tplst.
lc_va_vsart = vttkvb-vsart.
SELECT vbeln
FROM vttp
INTO TABLE lc_tb_vbeln
WHERE tknum = lc_va_tknum.
LOOP AT lc_tb_vbeln INTO lc_wa_vbeln.
SELECT SINGLE kunnr lifex
FROM likp
INTO (lc_va_kunnr, cs_header-mbcnr)
WHERE vbeln = lc_wa_vbeln-vbeln.
SELECT *
FROM lips
INTO TABLE lc_tb_lips
WHERE vbeln = lc_wa_vbeln-vbeln.
ENDLOOP.
LOOP AT lc_tb_lips INTO lc_wa_lips.
SELECT SINGLE pvvkz
FROM /Z2a/ldm_kun
INTO lc_va_pvvkz
WHERE kunnr = lc_va_kunnr.
IF lc_va_pvvkz NE 'X'.
cf_retcode = 4.
EXIT.
ELSE.
SELECT SINGLE exnum segal
FROM eikp
INTO (lc_va_exnum, lc_va_flag_zoll)
WHERE refnr = lc_wa_lips-vbeln.
SELECT SINGLE exprf
FROM eipo
INTO lc_va_exprf
WHERE exnum = lc_va_exnum
AND expos = lc_wa_lips-posnr.
lc_va_keyseg = lc_va_exprf.
CALL FUNCTION '/ZTR/P000_MCDATA_FROM_'
EXPORTING
cv_va_keytyp = '/Z2a/KEY_CU_PVABWICKLUNG'
cv_va_keyseg = lc_va_keyseg
TABLES
cr_tb_bwdat = lc_tb_bwdat.
IF NOT lc_tb_bwdat[] IS INITIAL.
LOOP AT lc_tb_bwdat INTO lc_wa_bwdat.
lc_wa_bwm_result = lc_wa_bwdat-datseg.
IF lc_wa_bwm_result-pv_relevant = 'X'.
* Kumulieren
lc_wa_cond-matnr = lc_wa_lips-matnr.
SELECT SINGLE maktx
FROM makt
INTO lc_wa_cond-arktx
WHERE matnr = lc_wa_lips-matnr
AND spras = 'DE'.
lc_wa_cond-menge = lc_wa_lips-lfimg.
lc_wa_cond-me = lc_wa_lips-meins.
COLLECT lc_wa_cond INTO lc_tb_cond.
ENDIF.
ENDLOOP.
ENDIF.
ENDIF.
ENDLOOP.
cs_header-kunnr = lc_va_kunnr.
SELECT SINGLE name1 name2 land1
INTO (cs_header-name1,
cs_header-name2,
lc_va_land1)
FROM kna1
WHERE kunnr = lc_va_kunnr.
SELECT SINGLE landx
INTO cs_header-land
FROM t005t
WHERE spras = sy-langu
AND land1 = lc_va_land1.
* Sortieren Aufsteigend nach Materialnr
SORT lc_tb_cond ASCENDING BY matnr.
* Übergabe an Ausgabetabelle
LOOP AT lc_tb_cond INTO lc_wa_cond.
MOVE-CORRESPONDING lc_wa_cond TO lc_wa_daten.
APPEND lc_wa_daten TO lc_tb_daten.
ENDLOOP.
ENDFORM. " get_data_spat
FORM set_print_data_to_read
USING if_formname LIKE tnapr-sform
CHANGING cs_print_data_to_read TYPE ledlv_print_data_to_read
cf_retcode.
FIELD-SYMBOLS: <fs_print_data_to_read> TYPE xfeld.
DATA: lt_fieldlist TYPE tsffields.
DATA: ls_fieldlist TYPE LINE OF tsffields.
DATA: lf_field1 TYPE LINE OF tsffields.
DATA: lf_field2 TYPE LINE OF tsffields.
DATA: lf_field3 TYPE LINE OF tsffields.
CALL FUNCTION 'SSF_FIELD_LIST'
EXPORTING
formname = if_formname
* VARIANT = ' '
IMPORTING
fieldlist = lt_fieldlist
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
IF sy-subrc <> 0.
cf_retcode = sy-subrc.
CLEAR lt_fieldlist.
ELSE.
* set print data requirements
LOOP AT lt_fieldlist INTO ls_fieldlist.
SPLIT ls_fieldlist AT '-' INTO lf_field1 lf_field2 lf_field3.
* <<<< START_OF_INSERTION_HP_350342 >>>>
IF lf_field1 = 'IS_DLV_DELNOTE' AND lf_field2 = 'IT_SERNR'.
lf_field2 = 'IT_SERNO'.
ENDIF.
* <<<< END_OF_INSERTION_HP_350342 >>>>
ASSIGN COMPONENT lf_field2 OF STRUCTURE
cs_print_data_to_read TO <fs_print_data_to_read>.
IF sy-subrc = 0.
<fs_print_data_to_read> = 'X'.
ENDIF.
ENDLOOP.
* header data is always required
cs_print_data_to_read-hd_gen = 'X'.
* adress is always required for print param
cs_print_data_to_read-hd_adr = 'X'.
* organisational data is always required for include texts
cs_print_data_to_read-hd_org = 'X'.
ENDIF.
ENDFORM. " set_print_data_to_read
*& Form set_print_param
* text
* -->P_LS_ADDR_KEY text
* <--P_LS_CONTROL_PARAM text
* <--P_LS_COMPOSER_PARAM text
* <--P_LS_RECIPIENT text
* <--P_LS_SENDER text
* <--P_CF_RETCODE text
FORM set_print_param USING is_addr_key LIKE addr_key
* lc_va_tknum
lc_va_lfnr TYPE nrlevel
CHANGING cs_control_param TYPE ssfctrlop
cs_composer_param TYPE ssfcompop
cs_recipient TYPE swotobjid
cs_sender TYPE swotobjid
cf_retcode TYPE sy-subrc.
DATA: ls_itcpo TYPE itcpo.
DATA: lf_repid TYPE sy-repid.
DATA: lf_device TYPE tddevice.
DATA: ls_recipient TYPE swotobjid.
DATA: ls_sender TYPE swotobjid.
DATA: lc_va_suffix TYPE rspo2name.
lf_repid = sy-repid.
CALL FUNCTION 'WFMC_PREPARE_SMART_FORM'
EXPORTING
pi_nast = nast
pi_addr_key = is_addr_key
pi_repid = lf_repid
IMPORTING
pe_returncode = cf_retcode
pe_itcpo = ls_itcpo
pe_device = lf_device
pe_recipient = cs_recipient
pe_sender = cs_sender.
SHIFT lc_va_lfnr LEFT DELETING LEADING '0'.
CONCATENATE 'PV' lc_va_lfnr INTO lc_va_suffix.
IF cf_retcode = 0.
MOVE-CORRESPONDING ls_itcpo TO cs_composer_param.
cs_composer_param-tdsuffix2 = lc_va_suffix.
cs_control_param-device = lf_device.
cs_control_param-no_dialog = 'X'.
cs_control_param-preview = screen.
cs_control_param-getotf = ls_itcpo-tdgetotf.
cs_control_param-langu = nast-spras.
ENDIF.
ENDFORM. " set_print_param
FORM protocol_nast_update.
CALL FUNCTION 'NAST_PROTOCOL_UPDATE'
EXPORTING
msg_arbgb = '/Z2a/PVSCHEIN'
msg_nr = '001'
msg_ty = 'E'
* MSG_V2 = SYST-MSGV2
* MSG_V3 = SYST-MSGV3
* MSG_V4 = SYST-MSGV4
* MSG_V1 = SYST-MSGV1
EXCEPTIONS
OTHERS = 1.
ENDFORM.Hello!
I have to customize the enclosed source code so it does the following:
print out for each shipment (see FuBa:RV_SHIPMENT_PRINT_VIEW
parameter slp) really seperated by for every shipment item LIKP-VBELN
and not for the whole VTTP-TKNUM.
The parameter "slp" must be stripted so by leaving
of the routine "get_data_pv" has only the datas of the current
LIKP-VBELN, and in the next step taking the next LIKP-VBELN
and so on. Right now it performs only one time for one VTTP-TKNUM.
If you don't understand VTTP-TKNUM and LIKP-VBELN please refer
to Transaction SE11.
Reagrds
Ilhan -
Purchase Order Print out with Digital Signature
Dear Gurus,
1) we are going to implement release strategy, but still business requirement to have a digital signature, Meaning, if only upto Supervisor release, then PO print should come with Supervisor digital signature, if PR value upto Supervisor & manager release, then PO print should come with Manager digital signature, if PR value upto Supervisor, Manager, GM Reelease, then PO print should come with GM digital signature, Whoever approves last, then their signature should appear in the PO printout - How to Achieve this?
2) If any amement in the Purchase order, then is it possible to reflect in the PO print out as Rev1 , Rev 2...?
Please advice
Thanks
RSDear,
Check : http://help.sap.com/saphelp_nw70/helpdata/EN/18/ecb69017ad4765855425b97f666470/content.htm
May be helpful.
Another is scan the signature to bmp and attach the bmp through smartform or sapscript - But this is not digital signature.
Regards,
Syed Hussain. -
Unable to take print out of JPEG image of DMS Document
Hi Expert,
I have used below method to print document.
CALL METHOD cl_gui_frontend_services=>execute
EXPORTING
document = w_string
operation = 'PRINT'.
I am able to take print out of all documents except JPEG.
Could any one help me out to do the same?
Thanks,
Jay.Hi,
see three possibles solution:
First: Solution! (Hopefully) :Print label image in GIF format
But I also used two different solutions to distinct problems.
I used SE78 functions dynamically to print an image for SmartForm.
In another situation I used a DVS Repro solution from SEAL Systems. -
Print-out of shopping carts - add additional informations
Hi SRM-experts,
one simple question. Is it possible without modification to add in the print-out of the shopping cart additional informations such as the purchase order number. Is there a possibility to customize that function ? Thanks for yours replies.
AWHello,
This will need small enhancement in the smatform. You will find it easy.
Use T-Code SMARTFORMS and copy the standard smartform for SC layout "BBP_SC" and create a Z-one and use that by implementing the BADI BBP_CHANGE_SF_SC.
You can get the PO value from the table BBP_PDBEI.
Hope this solves the issue.
Thanks
Ashu -
Print Out of Check List In Maintenance Order.
Hi All
I just added one checklist to the Long Text in the tasklist of an equipment.
In the checklist there are some tabular cloumns, lines, square box, etc...
But when i take a print out of the checklist/Orerations from the maintenance order the tabular cloumns, lines, square box, etc...
are not shown in the print out.
Pls. Suggest some way of adding the checklist with tabular cloumns, lines, square box, etc...
VenkatVenkat,
Long text doesn't support table formats.
You could get around it by having those fields maintained as characteristics and then generating a table while printing forms with that data using Adobe forms, smartform or sap script.
If you would still like to maintain the same in long text, it can be done by drawing vertical and horizontal lines using "|" AND "_" .Its tedious and ugly process, but you could get what you want.However the you may have to go through a iterative process to get the format right. It would be easier if there were just two columns.
Regards
Narasimhan -
Steps involved to Configure a Smartform for printing TO Item
Hi,
I want to develop a Smartform to print TO for each Item.
Currently it is being done using SAP Script.
I checked the Configuration in OMLV and assigned my print program Z****** .
This thing here is I don't see any values passed to my program like TO Number, Whse Number etc when called through LT31.
Where as I assign the standard program RLVSDR40 and debug it all the details are being passed to this program.
I am not sure if I am missing any configuration.
Please help me to figure out the issue and let me know all the steps involved in configuring the Smartforms to print Transfer Orders.
Thanks in Advance.
MK.Hi Murali,
The SAP delivers the solution to print the TO item by SAPScript, but we can do it by Smartform as well, as in
You need to create a project for the enhancement MWMD0001, because EXIT_RLVSDR40_001 will fulfill your purpose of doing it the other ways i.e. via Smart from.
For this you have to use CMOD transaction to create the project for the above said enhancement.
Note: If you do this way any configuration done via OMNU wont't be considered.
Then after in teh import parameters you have a table XRLDRI, which contains both the warehouse number and the transfer order number, the same can be passed on to the designed Smartform to fulfill your purpose.
Sample Code, you can refer to:
*local variable declaration.
DATA: l_wa_fm_name TYPE rs38l_fnam.
* Local Field Symbols
FIELD-SYMBOLS : <l_fs_rldri> TYPE rldri.
* Local Constant declaration
CONSTANTS : lc_fmname TYPE tdsfname VALUE 'XYXYXYXY', "Smartform name, here designated by 'XYXYXYXY'
lc_chk TYPE rldrudruck VALUE 'X'.
*Moving Transfer Order Print :Item level data into corresponding work area.
LOOP AT xrldri ASSIGNING <l_fs_rldri>.
* Determine smartform function module
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = lc_fmname
IMPORTING
fm_name = l_wa_fm_name
EXCEPTIONS
no_form = 1
no_function_module = 2
OTHERS = 3.
IF sy-subrc = 0.
* Call the function module of the smartform
CALL FUNCTION l_wa_fm_name
EXPORTING
user_settings = lc_chk
tanum = <l_fs_rldri>-tanum
lgnum = <l_fs_rldri>-lgnum
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5.
IF sy-subrc = 0.
ENDIF.
ENDIF.
ENDLOOP."LOOP AT xrldri ASSIGNING <l_fs_rldri>.
Please validate the same at your end and let me know in case you require any further inputs from my end.
BR/Thanks
Pranav Agrawal
Maybe you are looking for
-
No more .doc conversion in iPad Pages 2.0 / iOS 7?
I have an ongoing need to e-mail Pages documents from my iPad as Word (.doc) files to recipients who cannot work with Word 2007 (.docx) files. That was never a problem before, when Pages for iPad used the .doc format, which any MS Word user could see
-
How to get a error message when sms is not sent to a mobile no.
Scenario: once po is finally released sms is sent to the respective vendor.This has been done. But, Now the client want to see the error details(i.e, the mobile no. to whom sms i s sent) if the sms is not sent to any mobile no. and also wants a z pro
-
Dear All, We encountered an issue with one of our customers regarding the definition of WFu2019s path. The customer has a WF : START -> risk manager -> business manager 1 -> business manager 2 (**) -> auth. Manager -> FINISH (**) u2013 The second ap
-
Am I able to use a Hawking 300 Range Extender with the Apple Extreme connected to a PC?
I am puchasing an Apple Extreme to replace a Linksys router connected to a PC with Win7. I have been using two Hawking 300 Range extenders to get a better single throughout my home. Will I be able to continue to connect the Hawking 300 Range Extend
-
I have a DSL connection through Verizon that requires a username and password to get connected and once connected is always on. Now when I set this up with the DSL Modem/Router(it is a full router with all capabilites for networking like Linksys or A