Using QR Code for ITEM instead of Barcode . looking for suggestions

Discussion in 'Free Source Codes' started by Bhawna, Jul 9, 2021.

    
  1. Bhawna

    Bhawna Member


    Dear Admin

    I am currently using a barcode for Stock Item (Alias) using the TDL. Is there a way I could use QR Code for Stock Item Labels? Would appreciate any inputs regarding the same. Thanks

    TDL currently used

    ;; Sri Ganeshji : Sri Balaji : Sri Pitreshwarji : Sri Durgaji : Sri Venkateshwara

    /*
    Objective(s) :-
    - To Print Barcode for the Stock Items

    Specific TDL Feature(s) used :-
    - Repeat attribute at Part Level
    - Explode attribute at Line Level
    - Creation of new Style using Bar coding Font ‘IDAutomationHC39S’
    - User Defined Function to replace "" (Space) with "=" symbol as this font ‘IDAutomationHC39S’ treats "=" as space.

    Last Updation :-
    - Altered on 17/06/2010
    */

    ;; Adding Label Printing Report to the already existing Report

    [#Form: Purchase Color]

    Add : Print : TSPL FFE LabelPrint
    Add : Button : TSPL FFE LabelPrint
    [Button : TSPL FFE LabelPrint]
    Action :print Report: TSPL FFE LabelPrint
    Key :ctrl+F6
    ;;Label Printing Report

    [Report: TSPL FFE LabelPrint]

    Form : TSPL FFE LabelPrint
    Object : Voucher

    [Form: TSPL FFE LabelPrint]

    Part : TSPL FFE LabelPrint
    Width : 125 MMS
    FullHeight : Yes


    [Part: TSPL FFE LabelPrint]

    Parts : TSPL FFE LabelPrint1,TSPL FFE LabelPrint2
    Vertical :No



    [Part: TSPL FFE LabelPrint2]
    Use: TSPL FFE LabelPrint1


    [Part: TSPL FFE LabelPrint1]

    Line : TSPL FFE LabelPrint
    Repeat : TSPL FFE LabelPrint : Inventory Entries
    Scroll : Vertical


    [Line: TSPL FFE LabelPrint]

    Field : TSPL FFE StkItemLabel1, TSPL FFE StkItemLabel2
    Explode : TSPL FFENLine
    Explode : TSPL FFE MoreLabels : $$Number:$BilledQty > 1
    Space Bottom : .75


    [Field : TSPL FFE StkItemLabel2]
    Use : Name Field
    Set as : $StockItemName
    Style : Normal
    Inactive : Yes


    [Part : TSPL FFENLine]
    Lines : TSPL FFENLine3, TSPL FFENLine2


    [Line : TSPL FFENLine2]
    Fields : TSPL FFE StkItemLabel2
    Local : Field : TSPL FFE StkItemLabel2: Set as : $TSPLFEEStkAlias:StockItem:$StockItemName
    Local : Field : TSPL FFE StkItemLabel2: Inactive: $$IsEven:$$ExplodeLevel+1
    Height : 5 MM

    [Line : TSPL FFENLine3]
    Fields : Info Field, TSPL FFERate
    Local : Field : Info Field : Info : "Rate: Rs "
    Local : Field : Info Field : Inactive: $$IsEven:$$ExplodeLevel+1
    Height : 5 MM



    [Field : TSPL FFERate]
    Use : Short Name Field
    Set as : $StandardPrice:StockItem:$StockItemName
    Inactive : $$IsEven:$$ExplodeLevel+1
    Style : Normal Bold
    Width : 100 MMS



    [Part: TSPL FFE MoreLabels]

    Line : TSPL FFE MoreLabels


    [Line: TSPL FFE MoreLabels]

    Field : TSPL FFE StkItemLabel1
    Explode: TSPL FFENLine
    Explode : TSPL FFE MoreLabels : $$Number:$BilledQty > ($$ExplodeLevel+$$Line) *2
    Space bottom : .75


    [Field: TSPL FFE StkItemLabel1]

    Use : Name Field
    Set as : "(" + @TSPLFEEBarcodeLF + ")"
    TSPLFEEBarcodeLF : $$TSPLFFEBarcodeString:mad:TSPLFEEStkName
    TSPLFEEStkName : If $$IsEmpty:($TSPLFEEStkAlias:StockItem:$StockItemName) then $StockItemName +
    else ($TSPLFEEStkAlias:StockItem:$StockItemName)
    Style : TSPL FFE BarCode
    Width : 125 MMS


    [Style: TSPL FFE BarCode]

    Font : IDAutomationHC39S
    Height : 14



    [#Object: StockItem]

    TSPLFEEStkAlias : $$Alias

    ;; Function to replace space with "="


    [Function: TSPL FFE BarcodeString]

    Parameter : TSPLFFEEBarcodeInput : String

    Variable : TSPLFFE Temp : String
    Variable : TSPLFFE Count : Number
    Variable : TSPLFFEEBarcodeOutput : String

    10 : Set : TSPLFFE Temp : ""
    20 : FOR TOKEN : TSPL TokenVar : ##TSPLFFEEBarcodeInput : " "
    30 : Set : TSPLFFE Temp : ##TSPLFFETemp + $$String:##TSPLTokenVar + "="
    40 : END FOR
    50 : SET : TSPLFFE Count : $$StringLength:##TSPLFFETemp
    60 : SET : TSPLFFEEBarcodeOutput : $$StringPart:##TSPLFFETemp:0:(##TSPLFFECount-1)
    70 : RETURN : ##TSPLFFEEBarcodeOutput

    ;; End-of-File
     


  2. ROHIT JAISWAR

    ROHIT JAISWAR Member


    Migrate to TallyPrime or TallyERP Minimum Rel 6.6.3 is Required
    Below is the Sample Code for QR Code
    Code:
    [#Part: STKI Basic]
       
        Add    : Right Part    : At End    : StockItem QRcode
       
    [Part: StockItem QRcode]
       
        Line        : Empty                   
        QRCode        : ($Name + ", Closing Balance: "    + $$String:$ClosingBalance) : True
        Width        : 20% screen
        Height        : 20% screen
     
    Bhawna likes this.


  3. ROHIT JAISWAR

    ROHIT JAISWAR Member



  4. Bhawna

    Bhawna Member


    Thanks Rohit Jaiswar . I am printing the Barcode Labels as of now . I want to print QR code instead . Wondering how to apply QR Code Style . I am not well versed with TDL. Tried some trial n error but did not work out. Could you please look at the barcode code n suggest how to convert to QR code
     


  5. ROHIT JAISWAR

    ROHIT JAISWAR Member


    Currently What are you using ERP or Prime?
    if Prime then it will easily workable or if ERP then you have to upgrade to the ERP Latest Release 6.6.3
     


  6. sameer batavia

    sameer batavia New Member


    can you share the tdl
     


  7. ankur daga

    ankur daga Member


    hi,
    whatever details you need in QR code, u have to change in the following line

    QRCode : ($Name + ", Closing Balance: " + $$String:$ClosingBalance) : True
     
    Bhawna likes this.


  8. Bhawna

    Bhawna Member


    Thanks Ankur and Rohit for suggestion. I am still not able to make a breakthrough . Sharing the details of the work , I have done so far and what I am trying to achieve


    Current Status
    1) Barcode TDL for Label Print - Attached (Using Alias for Barcode)
    2) Output - Attached

    Future Status

    Instead of Barcode on the Label , I am looking to get QR Code .

    Q : What changes need to be made in the TDL to achieve it

    Thankyou in anticipation

    P.S. I am testing it on Tally Prime
     

    Attached Files:



  9. Bhawna

    Bhawna Member


    Please check above for Barcode TDL
     


  10. Bhawna

    Bhawna Member


    Ankur - I have shared the details above. Would appreciate if you could look at it .thanks
     


  11. Bhawna

    Bhawna Member


    Thanks Rohit - I am using Tally Prime now . Could you please check the TDL and suggest changes to be incorporated
     



  12. There are 2 aspect of Barcode/QRcode
    1) Printing &
    2) Scanning

    Printing what ever you want you can do it like above either barcode or Qrcode and information in the same depends on what you want to SCAN
    example while making purhcase invoice you will print the QRCODE with information of purchase voucher number + Item name + QTY + RATE etc
    but while scanning the same you need to do what in the field is you need to decide and make a seperate module for it
     
    anwer and Bhawna like this.


  13. Bhawna

    Bhawna Member


    Thanks Sanjay for a quick reply . I am looking to Simply have a QR Code Generated (instead of barcode) based on Stock Item Name . While Inwarding Purchase , I create a new Item and Add an Alias for it and use the Same Alias for Billing by Scanning it .

    Hope I am able to explain the problem statement well. Would appreciate if you could suggest how to edit the above TDL to achieve it
     
    Last edited: Jul 15, 2021


  14. Sanjeev S

    Sanjeev S Active Member


    Mam,

    You want it to be printed on Barcode printer or Lasr/Inkjet?
     
    Bhawna likes this.


  15. Bhawna

    Bhawna Member


    Thanks Sanjeev Sir for checking . Looking to Print on the Barcode Printer

    I have shared the current TDL I am using for the Barcode Print (couple of posts above) . Want to Print QR Code instead of Barcode . Would appreciate inputs .
     


  16. Sanjeev S

    Sanjeev S Active Member


    I haven't tried but let me try and get back to you.
     
    Bhawna likes this.


  17. Bhawna

    Bhawna Member


    Thanks . Appreciate it
     


  18. Bhawna

    Bhawna Member


    Hi Sanjeev Sir - hope you were able to check on it . Will appreciate if you could provide some guidance on how to implement it
     


  19. Bhawna

    Bhawna Member


    Hello Sir - i am still not able to find a solution to it . Any suggestions or help will be highly appreciated
     


  20. Anshul Jain

    Anshul Jain New Member


    Sir,

    Very Nice Tool Developed. I am facing some issues that the Fonts printing on Barcode Label are very small.
    Please suggest..

    Thanks in Advance

    Anshul Jain
     


  21. Sanjeev S

    Sanjeev S Active Member


    QR is not a true type font and hence using normal tdl method doesn't work for QR code printing using barcode printer. You need software's such as Bar Tender/ Nice Label to create prn file and then use it through TDL.

    Bit complicated process, printer dependent but works fantastically, scans properly.

    Experts can throw more light on this process.
     


  22. Bhawna

    Bhawna Member


    Hello Sir - i am still not able to find a solution to it . Any suggestions or help will be highly appreciated



    —- thanks for the suggestions Sanjeev sir . I have tried to find an alternative by printing longer barcode instead . I am still stuck with a small problem. Could you please check and suggest

    ….
    [​IMG]
    Friends - trust you are and keeping safe and healthy .

    I have modified the barcode TDL for my specific requirements for printing on 4.2 inch * 1 inch labels .

    I am facing an error that the first line of barcode printed do not utilise the FULL Width

    example - I printed 8 qty , the first 2 barcode are compressed and rest 6 are full width . Not able to make out what is the error. Would appreciate if any of the forum members can guide on it .



    sharing code and screen shot


    • Code


    ;; Sri Ganeshji : Sri Balaji : Sri Pitreshwarji : Sri Durgaji : Sri Venkateshwara


    /*

    Objective(s) :-

    - To Print Barcode for the Stock Items


    Specific TDL Feature(s) used :-

    - Repeat attribute at Part Level

    - Explode attribute at Line Level

    - Creation of new Style using Bar coding Font ‘IDAutomationHC39S’

    - User Defined Function to replace "" (Space) with "=" symbol as this font ‘IDAutomationHC39S’ treats "=" as space.



    Last Updation :-

    - Altered on 17/06/2010

    */


    ;; Adding Label Printing Report to the already existing Report


    [#Form: Purchase Color]


    Add : Print : TSPL FFE LabelPrint

    Add : Button : TSPL FFE LabelPrint

    [Button : TSPL FFE LabelPrint]

    Action :print Report: TSPL FFE LabelPrint

    Key :ctrl+F6

    ;;Label Printing Report


    [Report: TSPL FFE LabelPrint]


    Form : TSPL FFE LabelPrint

    Object : Voucher


    [Form: TSPL FFE LabelPrint]


    Part : TSPL FFE LabelPrint

    Width : 3.8 inch


    [Part: TSPL FFE LabelPrint]


    Parts : TSPL FFE LabelPrint1,TSPL FFE LabelPrint2

    Vertical :No



    [Part: TSPL FFE LabelPrint2]

    Use: TSPL FFE LabelPrint1



    [Part: TSPL FFE LabelPrint1]


    Line : TSPL FFE LabelPrint

    Repeat : TSPL FFE LabelPrint : Inventory Entries

    Scroll : Vertical




    [Line: TSPL FFE LabelPrint]


    Field : TSPL FFE StkItemLabel1, TSPL FFE StkItemLabel2

    Explode : TSPL FFENLine

    Explode : TSPL FFE MoreLabels : $$Number:$BilledQty > 1

    Space Bottom : .75




    [Field : TSPL FFE StkItemLabel2]

    Use : Name Field

    Set as : $StockItemName

    Style : Normal

    Inactive : Yes



    [Part : TSPL FFENLine]

    Lines : TSPL FFENLine3, TSPL FFENLine2




    [Line : TSPL FFENLine2]

    Fields : TSPL FFE StkItemLabel2

    Local : Field : TSPL FFE StkItemLabel2: Set as : $TSPLFEEStkAlias:StockItem:$StockItemName

    Local : Field : TSPL FFE StkItemLabel2: Inactive: $$IsEven:$$ExplodeLevel+1

    Field : Vchno

    Local : Field : Vchno: Set as : $VoucherNumber

    Height : 4 MM


    [Field: Vchno]

    Use : Name Field

    Style : Italic

    Align : Right






    [Line : TSPL FFENLine3]

    Fields : Info Field, TSPL FFERate

    Local : Field : Info Field : Info : "Rate: Rs "

    Local : Field : Info Field : Inactive: $$IsEven:$$ExplodeLevel+1




    Height : 4 MM




    [Field : TSPL FFERate]

    Use : Short Name Field

    Set as : $StandardPrice:StockItem:$StockItemName

    Inactive : $$IsEven:$$ExplodeLevel+1

    Style : Normal Bold

    FullWidth : yes

    Align : Center




    [Part: TSPL FFE MoreLabels]


    Line : TSPL FFE MoreLabels



    [Line: TSPL FFE MoreLabels]


    Field : TSPL FFE StkItemLabel1

    Explode: TSPL FFENLine

    Explode : TSPL FFE MoreLabels : $$Number:$BilledQty > ($$ExplodeLevel+$$Line)

    Space bottom : .75





    [Field: TSPL FFE StkItemLabel1]



    Use : Name Field

    Set as : "(" + @TSPLFEEBarcodeLF + ")"

    TSPLFEEBarcodeLF : $$TSPLFFEBarcodeString:mad:TSPLFEEStkName

    TSPLFEEStkName : If $$IsEmpty:($TSPLFEEStkAlias:StockItem:$StockItemName) then $StockItemName +

    else ($TSPLFEEStkAlias:StockItem:$StockItemName)

    Style : TSPL FFE BarCode

    FullWidth: Yes





    [Style: TSPL FFE BarCode]


    Font : IDAutomationHC39S

    Height : 12




    [#Object: StockItem]


    TSPLFEEStkAlias : $$Alias


    ;; Function to replace space with "="




    [Function: TSPL FFE BarcodeString]



    Parameter : TSPLFFEEBarcodeInput : String



    Variable : TSPLFFE Temp : String

    Variable : TSPLFFE Count : Number

    Variable : TSPLFFEEBarcodeOutput : String



    10 : Set : TSPLFFE Temp : ""

    20 : FOR TOKEN : TSPL TokenVar : ##TSPLFFEEBarcodeInput : " "

    30 : Set : TSPLFFE Temp : ##TSPLFFETemp + $$String:##TSPLTokenVar + "="

    40 : END FOR

    50 : SET : TSPLFFE Count : $$StringLength:##TSPLFFETemp

    60 : SET : TSPLFFEEBarcodeOutput : $$StringPart:##TSPLFFETemp:0:(##TSPLFFECount-1)

    70 : RETURN : ##TSPLFFEEBarcodeOutput



    ;; End-of-File
     


  23. Sanjeev S

    Sanjeev S Active Member


    Please send your mail id and specify which printer you are using.

    I will try to provide you some inputs.
     
    Bhawna likes this.


  24. Bhawna

    Bhawna Member


    Sir I am using TSC TE 244 printer . Would look forward to your inputs on this thread
     


Share This Page