2007 Apr 25 5:21 AM
Hi,
How do i start working with barcode in Sapscripts and the version is 4.7 ides.
If possible can someone post a step by step guide to build a sapscript using
barcode.
thxs in adv
pv
2007 Apr 25 5:25 AM
Hi,
In se71--> go to character format there you will find a check option for Barcode display..
Include your Barcode in that character format,.. and write this character format name in the text elements..
Note : your Barcode needs to be included in the SAP...
reward if useful
regards,
nazeer
2007 Apr 25 5:32 AM
hi
Please go to this link for more details.
http://help.sap.com/saphelp_47x200/helpdata/en/d9/4a94c851ea11d189570000e829fbbd/content.htm
http://help.sap.com/saphelp_47x200/helpdata/en/ca/d45a12900d11d29e8b0000e8323350/frameset.htm
About Syntax in a form window:
/: PERFORM <form> IN PROGRAM <prog>
/: USING &INVAR1&
/: USING &INVAR2&
......
/: CHANGING &OUTVAR1&
/: CHANGING &OUTVAR2&
......
/: ENDPERFORMINVAR1 and INVAR2 are variable symbols and may be of any of the four SAPscript symbol types.
OUTVAR1 and OUTVAR2 are local text symbols and must therefore be character strings.
The ABAP subroutine called via the command line stated above must be defined in the ABAP report prog as follows:
FORM <form> TABLES IN_TAB STRUCTURE ITCSY
OUT_TAB STRUCTURE ITCSY.
...
ENDFORM.
The values of the SAPscript symbols passed with /: USING... are now stored in the internal table IN_TAB . Note that the system passes the values as character string to the subroutine, since the field Feld VALUE in structure ITCSY has the domain TDSYMVALUE (CHAR 80). See the example below on how to access the variables.
The internal table OUT_TAB contains names and values of the CHANGING parameters in the PERFORM statement. These parameters are local text symbols, that is, character fields. See the example below on how to return the variables within the subroutine.
From within a SAPscript form, a subroutine GET_BARCODE in the ABAP program QCJPERFO is called. Then the simple barcode contained there (First page, Next page, Last page) is printed as local variable symbol.
Definition in the SAPscript form:
/: PERFORM GET_BARCODE IN PROGRAM QCJPERFO
/: USING &PAGE&
/: USING &NEXTPAGE&
/: CHANGING &BARCODE&
/: ENDPERFORM
/
/ &BARCODE&
Coding of the calling ABAP program:
REPORT QCJPERFO.
FORM GET_BARCODE TABLES IN_PAR STUCTURE ITCSY
OUT_PAR STRUCTURE ITCSY.
DATA: PAGNUM LIKE SY-TABIX, "page number
NEXTPAGE LIKE SY-TABIX. "number of next page
READ TABLE IN_PAR WITH KEY PAGE.
CHECK SY-SUBRC = 0.
PAGNUM = IN_PAR-VALUE.
READ TABLE IN_PAR WITH KEY NEXTPAGE.
CHECK SY-SUBRC = 0.
NEXTPAGE = IN_PAR-VALUE.
READ TABLE OUT_PAR WITH KEY BARCODE.
CHECK SY-SUBRC = 0.
IF PAGNUM = 1.
OUT_PAR-VALUE = |. "First page
ELSE.
OUT_PAR-VALUE = ||. "Next page
ENDIF.
IF NEXTPAGE = 0.
OUT_PAR-VALUE+2 = L. "Flag: last page
ENDIF.
MODIFY OUT_PAR INDEX SY-TABIX.
ENDFORM.
Hope it helped you.
Cheers....
r
navjot
reward if helpfull
2007 Apr 25 5:36 AM
Hi Pandrangi,
Check this info.
Barcodes
A barcode label is a special symbology to represent human readable information such as a material number or batch number
in machine readable format.
There are different symbologies for different applications and different industries. Luckily, you need not worry to much about that as the logistics supply chain has mostly standardized on 3 of 9 and 128 barcode symbologies - which all barcode readers support and which SAP support natively in it's printing protocols.
Barcodes are nothing more than a font definition and is part of the style sheet associated with a particular SAPScript form. The most important aspect is to place a parameter in the line of the form that points to the data element that you want to represent as barcode on the form, i.e. material number. Next you need to set the font for that parameter value to one of the supported barcode symbologies.
Behind every output form is a print program that collects all the data and then pass it to the form. The form contains the layout as well as the font, line and paragraph formats. These forms are designed using SAPScript (a very easy but frustratingly simplistic form format language) or SmartForms that is more of a graphical form design tool.
http://www.sap-img.com/abap/details-information-about-sap-barcodes.htm
The scripts and smartforms you print, can be Labels to the shipments/parcels. What you see on covers of products, is a barcode alright, but the cover itself can be generated by a smartform/sapscript.
The basic use of a bar code is to provide machine readability.(Only machines can read that).
When say barcode is used in Purchase order Forms, and a third party tool reads this barcode information. It can get all the details regarding this Purchase order.
Barcode Standard
To Create a Bar code prefix:
1) Go to T-code - SPAD -> Full Administration -> Click on Device Type -> Double click the device for which you wish to create the print control -> Click on Print Control tab ->Click on change mode -> Click the plus sign to add a row or prefix say SBP99 (Prefix must start with SBP) -> save you changes , it will ask for request -> create request and save
2) Now when you go to SE73 if you enter SBP00 for you device it will add the newly created Prefix
Create a character format C1.Assign a barcode to the character format. Check the check box for the barcode.
The place where you are using the field value use like this
<C1> &itab-field& </C1>.
You will get the field value in the form of barcode.
Which barcode printer are you using ? Can you download this file and see.
http://www.servopack.de/Files/HB/ZPLcommands.pdf.
It will give an idea about barcode commands.
Hope this resolves your query.
<b>Reward all the helpful answers.</b>
Regards