Bank Allocations - Insert 2 fields Bill name and Bill date

Discussion in 'Tally Developer' started by Arun Prasath, Jun 14, 2012.

    
  1. Arun Prasath

    Arun Prasath Member


    Dear Sir,

    I want to add two fields in bank allocations.
    I have added. But the Values are appearing only in alter mode only. Why is that? Pls see below Codes.


    [#Line: Vch Bank Allocations Title]

    Add : Fields : After : Vch Bank AllocTransType : VCH Inv no, VCH Inv Dt
    Local : Field : VCH Inv no : set As : "Invoice No."
    Local : Field : VCH Inv Dt : set As : "Inv. Date."

    [Field : VCH Inv no]

    Use : Name Field
    Dynamic: ""
    Type : String : Forced
    Set Always: Yes
    Set as : If @@InvoiceInCreate OR $$IsEmpty:$$Value Then @SetVal Else $$Value
    SetVal: If $$Line = 1 Then $..AllLedgerEntries[1].BillAllocations.Name Else If $$Line = 2 Then $..AllLedgerEntries[1].BillAllocations[2].Name Else If $$Line = 3 +
    Then $..AllLedgerEntries[1].BillAllocations[3].Name Else If $$Line = 4 Then $..AllLedgerEntries[1].BillAllocations[4].Name +
    Else If $$Line = 5 Then $..AllLedgerEntries[1].BillAllocations[5].Name Else If $$Line = 6 Then $..AllLedgerEntries[1].BillAllocations[6].Name else ""
    Storage : BillInvNo
    Width : 15 MMS

    [Field : VCH Inv Dt]

    Use : Uni date field
    Use : Name Field
    Set As : If $$Line = 1 Then $..AllLedgerEntries[1].BillAllocations.BillDate Else If $$Line = 2 Then $..AllLedgerEntries[1].BillAllocations[2].BillDate Else If $$Line = 3 +
    Then $..AllLedgerEntries[1].BillAllocations[3].BillDate Else If $$Line = 4 Then $..AllLedgerEntries[1].BillAllocations[4].BillDate +
    Else If $$Line = 5 Then $..AllLedgerEntries[1].BillAllocations[5].BillDate Else If $$Line = 6 Then $..AllLedgerEntries[1].BillAllocations[6].BillDate else ""
    Storage : BillInvDt
    Width : 15 MMS

    [System : UDF]

    BillInvNo : String : 115
    BillInvDt : date : 147


    [#Line: Vch Bank Allocations]

    Add : field : After : Vch Bank AllocTransType: VCH Inv no , VCH Inv Dt

    Rgds,

    Arun
     



  2. Code:
    [#Line: Vch Bank Allocations Title]
     
        Add : Fields : After : Vch Bank AllocTransType : VCH Inv no, VCH Inv Dt
        Local : Field : VCH Inv no : set As : "Invoice No."
        Local : Field : VCH Inv Dt : set As : "Inv. Date."
     
     
    [#Line: Vch Bank Allocations]
     
        Add  : Field        : After : Vch Bank AllocTransType : VCH Inv no, VCH Inv Dt
     
     
    [Field : VCH Inv no]
     
        Use    : Name Field
        Type    : String : Forced
        Set Always: Yes
        Set as    : If $$InCreateMode Then $$CollectionField:$BillName:$$Line:DSDLedgerBills Else $BillInvNo
        Storage : BillInvNo
        Width    : 15 MMS
     
    [Field : VCH Inv Dt]
     
        Use    : Uni date field
        Use    : Name Field
        Set As    : If $$InCreateMode Then $$CollectionField:$BillDate:$$Line:DSDLedgerBills Else $BillInvDt
        Storage : BillInvDt
        Width    : 15 MMS
     
    [System : UDF]
     
        BillInvNo : String    : 115
        BillInvDt : date    : 147
     
     
     
    [Collection : DSD Ledger Bills]
        Source Collection : ..
        WAlk            : AllLedgerEntries,BillAllocations
        BY                : LedgerName : $LedgerName
        By                : BillName    : $Name
        Compute        : BillDate    : $BillDate
        Aggr Compute    : Amount    : SUM : $Amount
       
        Format : $BillName,10
        Format : $BillDate,10
    
    Hi,
    Find the Corrected Code
     
    Arun Prasath likes this.


  3. Arun Prasath

    Arun Prasath Member



    Thanks Sir
     


  4. Girdhar

    Girdhar Member


    Great help sir.
     


Share This Page