Msg: 4321 *Conference*
05-15-93 15:37:06
From: CARROLL LEWIS
To : FRANK HENZE
Subj: BAR CODES
FRANK, Your search for the Tandy program 26-3845, will actually end at Tandy. I purchased mine from them in April. The current price is $2.95 (a far cry from the orignal price of $29.95). You can call 1-800-321-3133 and order it yourself (with a credit card), or go to a "shack" and HOPE that someone there will get it done for you. Since the program is still available I fear that reproductin might be a Copywrite no-no. But once you have it, I hope this will help. My meaasge #7748, (in conference) shows the changes that Epson required, and will be referred to . In original program, line 115 is where 3of9 (and Codabar) code is printed, and as such, is where changes will be made. Not being famillar with your printer, I can't be specific here but..command by command here's what' happen'. 115 LPRINTE;: (As best I can tell this sets a Tandy printer to dot graphics. "E" got it's value on line 225) FORZ=1TO3: (This loop sets the height of the code. I changed this to four.) LPRINTK;: (The value of "K" is established on line 150 as 'D(42)+B(0)' and is "*", the start and end code for 3of9.) FORY=1TOX: (This loop is the # of characters in the code to be printed. X got it's value on line 15 as 'X=LENG'. "G" is the line to be printed.) LPRINTD(INSTR(A,MID$(G,Y,1)));B(0);: (This is the heart of the code printing and should not be messed with. "D()" is dimensioned in line 155 and each of the 44 gets it's value from data in line 165. The data are "read" on line 155. "A" also gets it's value in line 155, "Y" from the loop statement, and finally "B(0)" which also was set in 155.) NEXT: (This is the end of the "Y" loop and untill Y=X returns to print the code for the next character in the string "G".) LPRINTK: (Once all the characters have been printed another "*" is printed as the stop code.) NEXT: (This is the end of the "Z" loop and will return to print the whole thing again untill the code is as tall as it should be.) LPRINTD;L;: (Here I can only assume that this is a command to the Tandy printer as a return to normal printing. Both "D" and "L" get their value on line 225. This command should have been omitted in my changes in message # 7748 but seems to have no effect with the Epson.) RETURN (of course) The other change that might be required is in line 235, where "X"and "V" get their values. For the Epson "X=128" had to be changed to "X=0" At this point it would be best to "see" what is going on, so load ' BCODE.BA' and run it as tho it's going to work. When "Select File to print" shows up "shift/break" and type: X=LEN(A):FOR Z=1TOX:?D(Z):NEXTZ <ENTER> What will "pass before your eyes" is not your life, but the "pictures" of each character code that can be printed. In 3of9 there are 44. Each field of dots (the CHR$ value of V) will be a single vertical line of dots (8 dots tall) on paper. Each "telephone" (the CHR$ value of X) will be a space one dot wide. (The Epson prints this as one dot at the top rather than a true space.) All of these "pictures" are 19 CHR$ characters long. Keeping in mind that "B(0)" was added to each character, now type: ?B(0) <ENTER> and you will see two telephones. Thus each 3of9 character of code will be 21 dots long. This is of absolute importance to the printer so that it knows how many dots to print on a line. Now look at the new line 115 (message 7748) 115 LPRINTCHR$(27);"A";CHR$(8);: (This is a command to Epson that sets the paper advance to 8 dots, so that each line of code is printed directly under the one above without spaces or overlaps.) X3=42+(X*21): (This the formula for how many dots long this "G" is. The 42 came from the two times the "*" code is printed automatically by the program. "X" here is LEN(G). IFX3<256 THEN X1=X3:X2=0ELSE X1=X3MOD256:X2=INT(X3/256) (This coparison is done to be able to satisfy the Epson's dot graphics commands. The varibles X1,X2,X3 were used here because they are not part of the orignal program.) 116 FORZ=1TO4: (This is the "how tall" loop.) LPRINTCHR$(27);"L";CHR$(X1);CHR$(X2): (This command shifts the Epson into dot graphics,"L" is double density (the best format in bar codeing) and the formula on line 115 is put to use. IT IS THIS SERIES OF COMMANDS that you will need to find the equivalent of,in your printer manual. Look for dot graphics and "Double density" and since 3of9 varies in lenght, the ability to controll the number of dots per line. The rest of line 116 is the same as the original 115 down to the last "next" 117 LPRINTCHR$(27);"2";:LPRINT (Returns the Epson to normal line spaceing, and advances the paper one line.) The rest of line 117 is the same as the end of the old 115. (again the 'LPRINTD;L;:' could have been left out.) Well, here's hoping that this LONG message is of value. If it raised more questions than answers I can try again. -Carroll Lewis-