Ref field in Reports @ basha

Discussion in 'Tally Developer' started by Nirav Merchant, Mar 1, 2013.

    
  1. Nirav Merchant

    Nirav Merchant Active Member


    Hi Basha pls find a sample code which i have made for one of my friend which shows ref field in Reports

    [#Field : VCH Ref Combo]
    Inactive : No
    Invisible : No
    Local : Field : Simple Prompt : Inactive : No
    Local : Field : Simple Prompt : Invisible : No

    [#Field : VCH Ref]
    Inactive : No
    Invisible : No

    [#Line : DB Title1]
    Add : Right Fields : After : DSP VchNumberTitle : DSP VchRefNoTitle
    [#Line : DSP VchAccTitles]
    Add : Right Fields : After : DSP VchNumberTitle : DSP VchRefNoTitle
    [#Line : DSP VchDetail]
    Add : Right Fields : After : DSP VchNumber : DSP VchRefNo
    [#Line : DSP VchInv1Titles]
    Add : Right Fields : After : DSP VchNumberTitle : DSP VchRefNoTitle
    Local : Field : DSP VchRefNoTitle : Set as : "Ref."
    [#Line : DSP VchInv2Titles]
    Add : Right Fields : After : DSP VchNumberTitle : DSP VchRefNoTitle
    Local : Field : DSP VchRefNoTitle : Set as : "No."
    [#Line : STKVCH NormalDetail]
    Add : Right Fields : After : DSP VchNumber : DSP VchRefNo
    [Field : DSP VchRefNoTitle]
    Use : Short Name Title Field
    Width : @@DSPNumberWidth + 2
    Info : "Ref No."
    Align : Right
    Invisible : ##BankRecMode OR $$InDraftMode
    Delete : Border

    [Field : DSP VchRefNo]
    Use : Name Field
    Width : @@DSPNumberWidth + 2
    Set as : $Reference;$$CollectionField:$ExcisePurchaseNumber:1:ExciseAllocations;$Reference ;;if Not $$IsVoucher then "" else
    ;;Set as : if Not $$IsVoucher then "" else @OptStr + $Reference;$$CollectionField:$ExcisePurchaseNumber:1:ExciseAllocations;$Reference ;;
    OptStr : if $IsOptional then "(Optional) " else ""
    Style : Small
    Align : Right
    Invisible : ##BankRecMode OR $$InDraftMode
    Delete : Border

    [#Field : DBC Qty]
    Set as : if $IsDeemedPositive:VoucherType:##VoucherTypeName then $$AsOutQty:$VchTotalQty else $$AsInQty:$VchTotalQty
    [#Part : DBC QtyDetails]
    Local : Field : DBC Qty : Set as : If NOT $$IsEmpty:$BilledQty then $BilledQty else $ActualQty
    [#Line : DSP VchExplosion]
    Add : Right Fields : DSP InBlock, DSP OutBlock, DSP ClBlock
    Local : Field : Default : Delete : Border
    Local : Field : DSP VchInQty : Set as : If @@IsInType then @@GetNewVal else ""
    Local : Field : DSP VchInAmt : Set as : ""
    Local : Field : DSP VchOutQty : Set as : If @@IsOutType then @@GetNewVal else ""
    Local : Field : DSP VchOutAmt : Set as : ""
    Local : Field : DSP VchClQty : Set as : ""
    Local : Field : DSP VchClAmt : Set as : ""
    ;___ @@-OBJECT-MODIFICATIONS ____________________________________________________________
    [#Object : Voucher]
    VchTotalQty : $$CollQtyTotal:InventoryEntries:$ActualQty

    ;___ @@-SYSTEM-FORMULA __________________________________________________________________
    [System : Formula]
    GetNewVal : If NOT $$IsEmpty:$BilledQty then $BilledQty else $ActualQty
    IsOutType : ($$IsDelNote:$VoucherTypeName OR $$IsSales:$VoucherTypeName OR $$IsCreditNote:$VoucherTypeName)
    IsInType : ($$IsRcptNote:$VoucherTypeName OR $$IsPurchase:$VoucherTypeName OR $$IsDebitNote:$VoucherTypeName)
    ;___ @@-END-OF-VCH-REFERENCE ____________________________________________________________

    [#Collection: Daybook Vouchers of Company]
    Fetch : reference

    [#Collection: Ledger Vouchers Coll]
    Fetch : reference

    [#Collection: Vouchers of Ledger]
    Fetch : reference
     


  2. admin

    admin Administrator Staff Member


    Great
     


  3. laxman

    laxman Member


    Good Tdl, but ref field with date field "purchase inv no & date "
     


  4. Ramu Angappan

    Ramu Angappan Member


    This is what i was searching for. Thanks a lot, I also need this reference field in Ledger Outstanding Reports. Could you please let me know what collection to update. I added these to your code but it didnt work

    [#Line: BILL Detail]
    Add : Fields : Before : BILLOp : DSP VchRefNo
    [#Collection: Ledger Bills]
    Fetch : reference
     


  5. Basha

    Basha Member


    Nirav after long time Thx lot.
     


  6. Sunder

    Sunder New Member


    Thxs Nirav Merchant. Could the reference field be added to Bills Outstanding report?
     



  7. please guide me where to activate the addon... i can see only same effect in outstanding report like before after installing it..
     


  8. Basha

    Basha Member


    Dear Kuber
    you have to chk Daybook and Customer Ledger
     


Share This Page