Authorized Signatory in Invoice Printing with affixed Stamp and Signature-- without company name

Discussion in 'Free Source Codes' started by Devendra_Rawat, Nov 3, 2018.

    
  1. Afjal Shaikh

    Afjal Shaikh New Member


    Hello Sir

    [#Part: CMP AccFeat Left]
    Add: Line: CMP EnableSignatureImage


    [Line: CMP EnableSignatureImage]
    Field: Medium Prompt, CMP EnableSignatureImage
    Local: Field: Medium Prompt: Info: "Enable Signature Print ? "

    Space Top: 1

    [Field: CMP EnableSignatureImage]
    Use: Logical Field
    Storage: EnableSignature
    Set as: If $$IsEmpty:$$Value then "No" else $$Value
    Sub Form: Cmp CompanySign Path: $$Value = "Yes"

    [Report : CMP CompanySign Path]

    Form : CMP CompanySign Path

    [Form : CMP CompanySign Path]

    Parts : Form SubTitle, CMP CompanySign Path
    Option : Small Size Form
    FullWidth : No
    FullHeight : No
    SpaceTop : 1
    SpaceBottom : 1
    SpaceLeft : 1
    SpaceRight : 1
    Background : @@SV_COSTCATEGORY
    Local : Field : Form SubTitle: Info : $$LocaleString:"Company Logo"
    Horizontal Alignment: Centre
    Vertical Alignment : Centre

    [Part : CMP CompanySign Path]

    Line : CMP CompanySign Path, CompanyLogo PathNotesOne

    [Line : CompanyLogo PathNotesOne]

    Field : CompanyLogo PathNotes
    Space Top : 1
    Space Bottom : 0.4

    Local : Field : CompanyLogo PathNotes: Set as : "- " + $$LocaleString:"Formats supported are BMP and JPEG."



    [Field: CompanyLogo PathNotes]

    Style : Normal Italic
    FullWidth : Yes
    Align : Left
    Skip : Yes
    Fixed : Yes

    [Line : CMP CompanySignPath]

    Fields : Medium Prompt, CMP CompanySign Path
    Local : Field : Medium Prompt : Info : $$Localestring:"Location of Signature:"

    [Field : CMP CompanySign Path]

    Use : Name Field
    Case : Normal
    Set as : $SignaturePath:Company:##SVCurrentCompany
    Storage : SignaturePath
    Setalways : Yes
    Width : @@LongWidth
    Max : 100
    Control : CMPLogoPathExist : ($$IsEmpty:$$Value OR Not $$IsFileExists:$$Value OR ($$FileSize:$$Value > 1048577))
    Modifies : SASignPath : Yes

    [System : Formula]

    CMPLogoPathExist : (If $$IsEmpty:$$Value then $$LocaleString:"Logo path cannot be empty." +
    Else If Not $$IsFileExists:$$Value then $$LocaleString:"Logo path specified is invalid or file not found." +
    Else IF $$FileSize:$$Value > 1048577 Then "File size exceeds 1 MB." +
    Else $$LocaleString:"Format Not Supported")

    [#Report: ChangeCurrentCompany]
    Local : Form : Modify Variables : On :Form Accept : Yes : SET : SASignPath:$SignaturePath:Company:##SvCurrentCompany

    [#Report: Voucher]
    SET : SASignPath:$SignaturePath:Company:##SvCurrentCompany

    [System:Variable]
    SASignPath : $SignaturePath:Company:##SvCurrentCompany

    [Variable: SASignPath]
    Type : String
    Persistent : Yes


    [System:UDF]
    EnableSignature : Logical : 1000
    SignaturePath : String : 1001



    [#Part: EXPINV Signature]

    Delete:Line: EXPSMP Signature
    Delete:Bottom Lines: EXPSMP Authourity

    Top Part : Test Image Part1
    Right Part : Test Image Part
    Bottom Part : Test Image Part2

    Vertical: Yes
    Height: 22 MMS
    Width: 95 MMS
    Option : Small Size Part
    Horizontal Align: Right
    Option : TraderInv AuthSignInfo : (@@IsDealerExciseSalesInvoice OR @@IsExciseMfgrRule11Invoice) AND NOT ##SATraderCommercial AND (NOT $$IsEmpty:##SAAuthorisedSignName OR NOT $$IsEmpty:##SAAuthorisedSignDesgn)



    [Part:Test Image Part]
    Line : Test Image Line

    Graph Type : ##SASignPath ;$SignaturePath:Company:##SVCurrentCompany
    Height : 15 mms
    Width : 95 mms
    Horizontal Align: Right
    Invisible : Not $EnableSignature:Company:##SVCurrentCompany ; If $$InPrintMode OR $$InMailAction OR ($$InExportMode And $$IsSysNameEqual:HTML:##SVExportFormat) then No Else Yes
    ;Height : If ((NOT $$InPrintMode) AND ($$InExportAction OR $$InMailAction)) Then 15% Else 8% Page

    [Part:Test Image Part1]
    Line : EXPSMP Signature
    Height: 4 mms

    [Part:Test Image Part2]
    Line : EXPSMP Authourity
    Height: 4 mms

    [Line:Test Image Line]
    Right Field: Test Image Field

    [Field:Test Image Field]
    Set as:""
    Alignment: Right


    I want signature file width large
    upload_2019-4-14_16-53-21.png upload_2019-4-14_16-53-21.png
     
    Last edited: Apr 14, 2019


  2. Afjal Shaikh

    Afjal Shaikh New Member



    Sir Meri Help Kardo Please
     


  3. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Kya help karein ??? ........ you have the code............ so make changes as per your requirements.

    [Part:Test Image Part]
    Line : Test Image Line

    Graph Type : ##SASignPath ;$SignaturePath:Company:##SVCurrentCompany
    Height : 15 mms Increase/Decrease as per your needs
    Width : 95 mms Increase/Decrease as per your needs

    Horizontal Align: Right
    Invisible : Not $EnableSignature:Company:##SVCurrentCompany ; If $$InPrintMode OR $$InMailAction OR ($$InExportMode And $$IsSysNameEqual:HTML:##SVExportFormat) then No Else Yes
     


  4. Afjal Shaikh

    Afjal Shaikh New Member




    upload_2019-4-14_17-49-7.png

    signture file ka width badana h sir nahi ho raha h
     


  5. Afjal Shaikh

    Afjal Shaikh New Member


    size badana h sir
     


  6. Afjal Shaikh

    Afjal Shaikh New Member



  7. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    MS Paint mei edit karke....size/width badha lo.............
     
    Afjal Shaikh likes this.


  8. Afjal Shaikh

    Afjal Shaikh New Member


    Thanks Sir
     


  9. Devendra_Rawat

    Devendra_Rawat Well-Known Member



  10. NAMAN WASAN

    NAMAN WASAN New Member


    Hello
    The above source code works perfectly fine when it comes to Exporting the invoice in a PDF format or viewing it as a a soft copy, but when i'm taking a print out directly from tally, the signature shifts upwards and clashes with the Bank Details section, rendering it useless. Please advice on how to fix this issue. I'm attaching the error image of the invoice and my printing specifications for reference. Let me know if anything needs to change? I'll highly appreciate it. Thank you.

    Regards
    Naman Wasan
     

    Attached Files:



  11. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Experiment with size reduction of your signature.jpeg file..........

    give condition.... If $$InPrintmode then so-and-so filename else export-wala-filename

    This happens because the dimensions of page changes while in print mode and in export mode.
     


  12. NAMAN WASAN

    NAMAN WASAN New Member


    I appreciate your prompt reply sir. But on changing the size, the position isn't changing. Any other way that can be tried?
     


  13. Devendra_Rawat

    Devendra_Rawat Well-Known Member


    Yes.. I am not able to solve it. .I think this TDL has structural issue.
     


  14. Devendra_Rawat

    Devendra_Rawat Well-Known Member


    though print to PDF printer (bullzip or pdf24) is doing perfectly well.

    you can print to actual printer from there.

    Only problem is printing with actual printer directly from Tally.
     


  15. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    never tried, so do not know....

    Only way to work this would be to wholly re-structure the entire print module.
     


  16. Jay kumar tailor

    Jay kumar tailor Well-Known Member


    Add extra part after company name and reduce size of sign part
     


  17. Jay kumar tailor

    Jay kumar tailor Well-Known Member


    Sir,
    Try This One.
    It`s Working (Also Added In Simple Invoice Format) After Modification,
    Just change Image part size and increase or decrease main part size with image part.
    As per your requirement.

    [#Part: CMP AccFeat Left]
    Add: Line: CMP EnableSignatureImage


    [Line: CMP EnableSignatureImage]
    Field: Medium Prompt, CMP EnableSignatureImage
    Local: Field: Medium Prompt: Info: "Enable Signature Print ? "

    Space Top: 1

    [Field: CMP EnableSignatureImage]
    Use: Logical Field
    Storage: EnableSignature
    Set as: If $$IsEmpty:$$Value then "No" else $$Value
    Sub Form: Cmp CompanySign Path: $$Value = "Yes"

    [Report : CMP CompanySign Path]

    Form : CMP CompanySign Path

    [Form : CMP CompanySign Path]

    Parts : Form SubTitle, CMP CompanySign Path
    Option : Small Size Form
    FullWidth : No
    FullHeight : No
    SpaceTop : 1
    SpaceBottom : 1
    SpaceLeft : 1
    SpaceRight : 1
    Background : @@SV_COSTCATEGORY
    Local : Field : Form SubTitle: Info : $$LocaleString:"Company Logo"
    Horizontal Alignment: Centre
    Vertical Alignment : Centre

    [Part : CMP CompanySign Path]

    Line : CMP CompanySign Path, CompanyLogo PathNotesOne

    [Line : CompanyLogo PathNotesOne]

    Field : CompanyLogo PathNotes
    Space Top : 1
    Space Bottom : 0.4

    Local : Field : CompanyLogo PathNotes: Set as : "- " + $$LocaleString:"Formats supported are BMP and JPEG."



    [Field: CompanyLogo PathNotes]

    Style : Normal Italic
    FullWidth : Yes
    Align : Left
    Skip : Yes
    Fixed : Yes

    [Line : CMP CompanySignPath]

    Fields : Medium Prompt, CMP CompanySign Path
    Local : Field : Medium Prompt : Info : $$Localestring:"Location of Signature:"

    [Field : CMP CompanySign Path]

    Use : Name Field
    Case : Normal
    Set as : $SignaturePath:Company:##SVCurrentCompany
    Storage : SignaturePath
    Setalways : Yes
    Width : @@LongWidth
    Max : 100
    Control : CMPLogoPathExist : ($$IsEmpty:$$Value OR Not $$IsFileExists:$$Value OR ($$FileSize:$$Value > 1048577))
    Modifies : SASignPath : Yes

    [System : Formula]

    CMPLogoPathExist : (If $$IsEmpty:$$Value then $$LocaleString:"Logo path cannot be empty." +
    Else If Not $$IsFileExists:$$Value then $$LocaleString:"Logo path specified is invalid or file not found." +
    Else IF $$FileSize:$$Value > 1048577 Then "File size exceeds 1 MB." +
    Else $$LocaleString:"Format Not Supported")

    [#Report: ChangeCurrentCompany]
    Local : Form : Modify Variables : On :Form Accept : Yes : SET : SASignPath:$SignaturePath:Company:##SvCurrentCompany

    [#Report: Voucher]
    SET : SASignPath:$SignaturePath:Company:##SvCurrentCompany

    [System:Variable]
    SASignPath : $SignaturePath:Company:##SvCurrentCompany

    [Variable: SASignPath]
    Type : String
    Persistent : Yes


    [System:UDF]
    EnableSignature : Logical : 1000
    SignaturePath : String : 1001



    [#Part: EXPINV Signature]

    Delete:Line: EXPSMP Signature
    Delete:Bottom Lines: EXPSMP Authourity

    Top Part : Test Image Part1
    Top Part : Test Image Part12
    Right Part : Test Image Part
    Bottom Part : Test Image Part2

    Vertical: Yes
    Height: 30 MMS
    Width: 35 MMS
    Delete: Border
    Option : Small Size Part
    Horizontal Align: Right
    Option : TraderInv AuthSignInfo : (@@IsDealerExciseSalesInvoice OR @@IsExciseMfgrRule11Invoice) AND NOT ##SATraderCommercial AND (NOT $$IsEmpty:##SAAuthorisedSignName OR NOT $$IsEmpty:##SAAuthorisedSignDesgn)


    [#Part: EXPSMP Signature]

    Delete:Line : EXPSMP Signature
    Delete:Bottom Lines: EXPSMP Authourity

    Top Part : Test Image Part1
    Top Part : Test Image Part12
    Right Part : Test Image Part
    Bottom Part : Test Image Part2

    Vertical: Yes
    Height: 30 MMS
    Width: 38 MMS
    Delete: Border
    Option : Small Size Part
    Horizontal Align: Right
    Option : TraderInv AuthSignInfo : (@@IsDealerExciseSalesInvoice OR @@IsExciseMfgrRule11Invoice) AND NOT ##SATraderCommercial AND (NOT $$IsEmpty:##SAAuthorisedSignName OR NOT $$IsEmpty:##SAAuthorisedSignDesgn)








    [Part:Test Image Part1]
    Line : EXPSMP Signature
    Height: 4 mms

    [Part:Test Image Part12]
    Line : blankline1
    Height: 8 mms

    [Part:Test Image Part]
    Line : Test Image Line

    Graph Type : ##SASignPath ;$SignaturePath:Company:##SVCurrentCompany
    Height : 13 mms
    Width : 38 mms
    Horizontal Align: Right
    Invisible : Not $EnableSignature:Company:##SVCurrentCompany ; If $$InPrintMode OR $$InMailAction OR ($$InExportMode And $$IsSysNameEqual:HTML:##SVExportFormat) then No Else Yes


    [Part:Test Image Part2]
    Line : EXPSMP Authourity
    Height: 4 mms

    [Line:blankline1]
    Right Field: Blank Field
    Space Top : If $$InPrintMode Then 1 Else 1
    [Field:Blank Field]
    Set as:""
    Alignment: Right

    [Line:Test Image Line]
    Right Field: Test Image Field
    Space Top : If $$InPrintMode Then 1 Else 1


    [Field:Test Image Field]
    Set as:""
    Alignment: Right
     
    Last edited: Apr 27, 2019


  18. NAMAN WASAN

    NAMAN WASAN New Member



    Thank you so much sir! This source code does what i was looking for. But with a very minor issue, The signature doesn't change its location even after printing it (thankfully) but the very location of it is on the left by default, it's not aligned (picture attached) . I'm very new to TDL language so let me know what change can be done in the above source code to shift the signature towards the right?
     

    Attached Files:



  19. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Put.... align : right
     


  20. Devendra_Rawat

    Devendra_Rawat Well-Known Member


    I have not received any mail "Jay Kumar"
     


  21. NAMAN WASAN

    NAMAN WASAN New Member


    where exactly should i put "align right" in this source code? i have no idea about TDL language so if you can help?
     


  22. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    In the source code......... there is

    Alignment: Right ............replace this with Align : Right

    Do not touch "Horizontal align"
     


  23. NAMAN WASAN

    NAMAN WASAN New Member


    no luck sir. This didn't work. the signature did not move even a bit.
     


  24. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    How would i know what you have done??
    and How?
     


  25. Jay kumar tailor

    Jay kumar tailor Well-Known Member


    Try Now.....

    [#Part: CMP AccFeat Left]
    Add: Line: CMP EnableSignatureImage


    [Line: CMP EnableSignatureImage]
    Field: Medium Prompt, CMP EnableSignatureImage
    Local: Field: Medium Prompt: Info: "Enable Signature Print ? "

    Space Top: 1

    [Field: CMP EnableSignatureImage]
    Use: Logical Field
    Storage: EnableSignature
    Set as: If $$IsEmpty:$$Value then "No" else $$Value
    Sub Form: Cmp CompanySign Path: $$Value = "Yes"

    [Report : CMP CompanySign Path]

    Form : CMP CompanySign Path

    [Form : CMP CompanySign Path]

    Parts : Form SubTitle, CMP CompanySign Path
    Option : Small Size Form
    FullWidth : No
    FullHeight : No
    SpaceTop : 1
    SpaceBottom : 1
    SpaceLeft : 1
    SpaceRight : 1
    Background : @@SV_COSTCATEGORY
    Local : Field : Form SubTitle: Info : $$LocaleString:"Company Logo"
    Horizontal Alignment: Centre
    Vertical Alignment : Centre

    [Part : CMP CompanySign Path]

    Line : CMP CompanySign Path, CompanyLogo PathNotesOne

    [Line : CompanyLogo PathNotesOne]

    Field : CompanyLogo PathNotes
    Space Top : 1
    Space Bottom : 0.4

    Local : Field : CompanyLogo PathNotes: Set as : "- " + $$LocaleString:"Formats supported are BMP and JPEG."



    [Field: CompanyLogo PathNotes]

    Style : Normal Italic
    FullWidth : Yes
    Align : Left
    Skip : Yes
    Fixed : Yes

    [Line : CMP CompanySignPath]

    Fields : Medium Prompt, CMP CompanySign Path
    Local : Field : Medium Prompt : Info : $$Localestring:"Location of Signature:"

    [Field : CMP CompanySign Path]

    Use : Name Field
    Case : Normal
    Set as : $SignaturePath:Company:##SVCurrentCompany
    Storage : SignaturePath
    Setalways : Yes
    Width : @@LongWidth
    Max : 100
    Control : CMPLogoPathExist : ($$IsEmpty:$$Value OR Not $$IsFileExists:$$Value OR ($$FileSize:$$Value > 1048577))
    Modifies : SASignPath : Yes

    [System : Formula]

    CMPLogoPathExist : (If $$IsEmpty:$$Value then $$LocaleString:"Logo path cannot be empty." +
    Else If Not $$IsFileExists:$$Value then $$LocaleString:"Logo path specified is invalid or file not found." +
    Else IF $$FileSize:$$Value > 1048577 Then "File size exceeds 1 MB." +
    Else $$LocaleString:"Format Not Supported")

    [#Report: ChangeCurrentCompany]
    Local : Form : Modify Variables : On :Form Accept : Yes : SET : SASignPath:$SignaturePath:Company:##SvCurrentCompany

    [#Report: Voucher]
    SET : SASignPath:$SignaturePath:Company:##SvCurrentCompany

    [System:Variable]
    SASignPath : $SignaturePath:Company:##SvCurrentCompany

    [Variable: SASignPath]
    Type : String
    Persistent : Yes


    [System:UDF]
    EnableSignature : Logical : 1000
    SignaturePath : String : 1001



    [#Part: EXPINV Signature]

    Delete:Line: EXPSMP Signature
    Delete:Bottom Lines: EXPSMP Authourity

    Top Part : Test Image Part1
    Top Part : Test Image Part12
    Right Part : Test Image Part
    Bottom Part : Test Image Part2

    Vertical: Yes
    Height: 25 MMS
    Width: 50 MMS
    Delete: Border
    Option : Small Size Part
    Horizontal Align: Right
    Option : TraderInv AuthSignInfo : (@@IsDealerExciseSalesInvoice OR @@IsExciseMfgrRule11Invoice) AND NOT ##SATraderCommercial AND (NOT $$IsEmpty:##SAAuthorisedSignName OR NOT $$IsEmpty:##SAAuthorisedSignDesgn)


    [#Part: EXPSMP Signature]

    Delete:Line : EXPSMP Signature
    Delete:Bottom Lines: EXPSMP Authourity

    Top Part : Test Image Part1
    Top Part : Test Image Part12
    Right Part : Test Image Part
    Bottom Part : Test Image Part2

    Vertical: Yes
    Height: 25 MMS
    Width: 50 MMS
    Delete: Border
    Option : Small Size Part
    Horizontal Align: Right
    Option : TraderInv AuthSignInfo : (@@IsDealerExciseSalesInvoice OR @@IsExciseMfgrRule11Invoice) AND NOT ##SATraderCommercial AND (NOT $$IsEmpty:##SAAuthorisedSignName OR NOT $$IsEmpty:##SAAuthorisedSignDesgn)








    [Part:Test Image Part1]
    Line : EXPSMP Signature
    Height: 4 mms

    [Part:Test Image Part12]
    Line : blankline1
    Height: 4 mms

    [Part:Test Image Part]
    Line : Test Image Line

    Graph Type : ##SASignPath ;$SignaturePath:Company:##SVCurrentCompany
    Height : 13 mms
    Width : 50 mms
    Horizontal Align: Right

    Invisible : Not $EnableSignature:Company:##SVCurrentCompany ; If $$InPrintMode OR $$InMailAction OR ($$InExportMode And $$IsSysNameEqual:HTML:##SVExportFormat) then No Else Yes


    [Part:Test Image Part2]
    Line : EXPSMP Authourity
    Height: 4 mms

    [Line:blankline1]
    Right Field: Blank Field
    Space Top : If $$InPrintMode Then 1 Else 1

    [Field:Blank Field]
    Set as:""
    Align : Right

    [Line:Test Image Line]
    Right Field: Test Image Field
    Space Top : If $$InPrintMode Then 1 Else 1


    [Field:Test Image Field]
    Set as:""
    Align: Right
     
    Last edited: Apr 27, 2019


Share This Page