Logical Field not working properly

Discussion in 'Free Source Codes' started by Partha Mondal, Feb 21, 2023.

    
  1. Partha Mondal

    Partha Mondal Member


    Dear all,
    Can anyone help me. My logical field is not working. I want when logical field value is Yes then
    bottom part before narration is enabled otherwise disabled.

    ;;; Voucher customization ;;;;;;

    [#Part: EI Consignee]

    Add : Line : Before : EI Consignee : AMCTaken

    [Line : AMCTaken]

    Field : Simple Prompt, AMCTaken ;, EI CurrConsignee, EI FirstLedger, INVMailName, Name Field

    Local : Field : Simple Prompt: Info : $$LocaleString:"Is AMC Invoice:"
    Local : Field : Simple Prompt: Width : @@VchLeftPromptWidth % Page
    Local : Field : Simple Prompt: Color : Blue

    [Field : AMCTaken]
    Use : Logical Field
    Storage : IsAMCInvoice

    ;; Bottom part customization ;;;;

    [#Part : VCH narration]

    Option : Part AMC : $IsAmcInvInput

    [!Part : Part AMC]

    Add : Line : At Beginning : AMC_Details

    [Line : AMC_Details]

    Field : Medium Prompt
    Local : Field : Medium Prompt : Set as : $$LocaleString:"AMC Details :"

    [System : UDF]

    IsAMCInvoice: Logical : 4008
     


  2. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    What and where is IsAmcInvInput ???
     


  3. balajimg

    balajimg Active Member


    [!Part : Part AMC]

    Invisible : NOT $IsAMCInvoice
     


  4. Partha Mondal

    Partha Mondal Member


    Dear all,
    After change my code when I input Yes showing bottom part but cursour not going to another field Party A/c name also if I input No
    it is also stack to this field not going to another field. Can anyone help me.

    ;;; Voucher customization ;;;;;;

    [System : UDF]

    IsAMCInvoice : Logical : 4008

    [#Part: EI Consignee]

    Add : Line : Before : EI Consignee : AMCTaken

    [Line : AMCTaken]

    Field : Simple Prompt, AMCTaken

    Local : Field : Simple Prompt: Info : $$LocaleString:"Is AMC Invoice:"
    Local : Field : Simple Prompt: Width : @@VchLeftPromptWidth % Page
    Local : Field : Simple Prompt: Color : Blue

    [Field : AMCTaken]

    Use : Logical Field
    Storage : IsAMCInvoice

    ;; Bottom part customization ;;;;

    [#Part : VCH narration]

    Option : Part AMC : $IsAMCInvoice

    [!Part : Part AMC]

    Add : Line : At Beginning : AMC_Details

    ;Invisible : not $IsAMCInvoice

    [Line : AMC_Details]

    Field : Medium Prompt
    Local : Field : Medium Prompt : Info : $$LocaleString:"AMC Details :"
     


  5. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    [#Part: EI Consignee]
    Line : EI Consignee, AMCTaken
     


  6. Partha Mondal

    Partha Mondal Member


    Not working. I use following your code. But now coming first Party A/c Name then logical field. But when I set yes it will back to Party A/c Name field
    not going to next field Sales ledger, Inventory details field.


    [#Part: EI Consignee]
    Line : EI Consignee, AMCTaken
     


  7. Bipin Damania

    Bipin Damania Active Member


    Working...

    upload_2023-2-23_6-14-7.png
     


  8. Partha Mondal

    Partha Mondal Member


    Dear Bipin Sir,
    Thank you for reply. I rectify my code but till now not working. Actually I want when Is AMC Invoice is yes
    then bottom part Part AMC is enabled. As per your snapshot. I don't understand where I am going wrong.
    It would be great if you could rectify it please.


    [#Part: EI Consignee]

    Add : Line : BEFORE : EI Consignee : AMCTaken

    [Line : AMCTaken]

    Field : Simple Prompt, AMCTaken

    Local : Field : Simple Prompt: Info : $$LocaleString:"Is AMC Invoice:"
    Local : Field : Simple Prompt: Width : @@VchLeftPromptWidth % Page
    Local : Field : Simple Prompt: Color : Blue

    [Field : AMCTaken]
    Use : Logical Field
    Storage : IsAMCInvoice

    ;; Bottom part customization ;;;;

    [#Part : VCH narration]

    Option : Part AMC

    [!Part : Part AMC]

    Add : Line : At Beginning : AMC_Details

    Invisible : NOT $IsAMCInvoice

    [Line : AMC_Details]

    Field : Medium Prompt
    Local : Field : Medium Prompt : Info : $$LocaleString:"AMC Details :"

    [System : UDF]

    IsAMCInvoice : Logical : 3000
     


  9. Bipin Damania

    Bipin Damania Active Member


    Instead of using Invisible at Line, use Inactive at Field.
     


  10. Partha Mondal

    Partha Mondal Member


    Thank you sir. working perfect.
     


  11. Mukesh1001

    Mukesh1001 New Member


    PLEASE HELP NOT SAVE YES UDF
    [#Part: DYBKCFG Common]
    Add : Line : After : DBKExplodeNarr : PWRF12DBKVchType


    [Line: PWRF12DBKVchType]
    Field : Medium Prompt, PWRF12DBKVchType
    Local : Field : Medium Prompt : Set as : "Show Vch Type ?"
    Space Bottom : 1 mm
    Space Top : 1

    [Field: PWRF12DBKVchType]
    Use : Logical Field
    Set as : $$Value
    Storage : PWRF12DBKVchType
    Background : Red


    [System : UDF]
    PWRF12DBKVchType : Logical : 5992

    [#Field: DSP VchType]
    Invisible : Not $PWRF12DBKVchType:Company:##SVCurrentCompany
     


  12. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Use Variable instead.........
     
    Last edited: Sep 10, 2023


  13. nasir

    nasir Member


     


  14. M K RAJU

    M K RAJU New Member


    Amit sir please correct my Field formula

    [Field: Field Name]
    Use : Number Field
    Set : ($Field1 + $Field2) / $Field3
    Set Always : Yes
    Storage : VCHFieldName
    Format : "Decimal:3"
    Width : 10

    calculator Result is =(5590+10)/5401 = 1.036

    above formula tally prime show 1.037 please correct
     


  15. M K RAJU

    M K RAJU New Member


    I want without rounding Numbers
     


  16. balajimg

    balajimg Active Member


    thats because the result is 1.0368

    in that case, u calculate for 4 decimals and display 3 decimals.
     


  17. M K RAJU

    M K RAJU New Member


    ok sir but rounddown formula not applicable this Field?
     


  18. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Tally will not consider beyond 4 decimals --- and since the result is 1.0368 - and based on your Format it will return 1.037 only.
     


  19. M K RAJU

    M K RAJU New Member



Share This Page