on 01-15-2008 4:57 AM
what r lables in sap scripts and smartforms ....pls lemme know ...its urgent
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Please check the following URL
Thanks&Regards,
Phani.
POINTS HELPFUL.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Akshit..
Labels in Sapscript..
Use
You want to print labels (such as shipping or bar code labels) on a special printer. You can create a label using an external design program and then print it from a SAPscript form.
Prerequisites
Most special label printers available on the market use their own control languages for which there is no printer driver in the standard SAP system. To be able to address these label printers nevertheless from the SAP System, you can define the complete layout with an external program.
Activities
1. Create the Label with a Design Program: Define the complete layout of the label, including the fields that are later filled from the SAP System.
2. Download the Print File: Export the file with the print command from the design program. The printer commands must be in ASCII format; that is only printable characters and CARRIAGE RETURN, LINEFEED, and possibly FORMFEED can be contained. The file must also not have more than 80 characters per line, as otherwise undesired line breaks could occur during the upload. Binary control characters (such as ESCAPE) must not be included. (For more information about the download, see the sections listed below for the relevant label printers).
3. Upload the Print File to the SAPscript Form: Upload the print file to a SAPscript standard text. However, this standard is only used as a temporary store. Copy the text to a SAPscript form. In the form, enter variables of the print program (program symbols) in the places where data should appear in the label. These variables are filled with the current field values from the application program during runtime. (For more information about the upload, see the sections listed below for the relevant label printers).
4. Adjust the form: You now need to adjust the label for most label printers, for example, you must increase the MAIN window to the full page size and close all other windows. The MAIN window should also only contain a single text element; that is, the imported print file.
5. Create an Output Device: Define an output device for label printing. You can use either ASCIIPRI or a special device type for label printers as the device type.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Aakash..
Labels cannot be created in smartforms but we can create them in Sapscripts..
Sample Sapscripts Label Printing Program
TABLES : ZPACK,ZTRN.
DATA: BEGIN OF ITAB OCCURS 0,
ZPKSLIP_NO LIKE ZTRN-ZPKSLIP_NO,
ZCARTON_NO LIKE ZPACK-ZCARTON_NO,
END OF ITAB.
DATA MVAR(12) TYPE C.
DATA MCTR(6) TYPE C.
SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
SELECT-OPTIONS: ZSLIP FOR ZTRN-ZPKSLIP_NO NO-EXTENSION NO INTERVALS
OBLIGATORY default 6.
SELECTION-SCREEN END OF BLOCK B1.
SELECT * FROM ZPACK INTO CORRESPONDING FIELDS OF TABLE ITAB WHERE
ZPKSLIP_NO EQ ZSLIP-LOW .
CALL FUNCTION 'OPEN_FORM'
EXPORTING
FORM = 'ZTEST_RAJ'.
DO 4 TIMES.
MCTR = 100000 + SY-INDEX.
MCTR = MCTR+1(5).
CONCATENATE '55C/06/' MCTR INTO MVAR.
DO 80 TIMES.
ITAB-ZPKSLIP_NO = MVAR.
ITAB-ZCARTON_NO = SY-INDEX.
APPEND ITAB.
CLEAR ITAB.
ENDDO.
ENDDO.
SORT ITAB BY ZPKSLIP_NO ZCARTON_NO.
CALL FUNCTION 'START_FORM'
EXPORTING
FORM = 'ZTEST_RAJ'.
LOOP AT ITAB.
AT NEW ZPKSLIP_NO.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = '101'
WINDOW = 'MAIN'.
ENDAT.
CALL FUNCTION 'WRITE_FORM'
EXPORTING
ELEMENT = '102'
WINDOW = 'MAIN'.
AT END OF ZPKSLIP_NO.
CALL FUNCTION 'END_FORM'.
CALL FUNCTION 'START_FORM'
EXPORTING
FORM = 'ZTEST_RAJ'.
ENDAT.
ENDLOOP.
CALL FUNCTION 'END_FORM'.
CALL FUNCTION 'CLOSE_FORM'.
In sap script write :
/E 101
P1 ,,&ITAB-ZPKSLIP_NO(R)&
P1
/E 102
P1 ,,&ITAB-ZCARTON_NO(R)&
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.