Partywise Sales value

Discussion in 'Tally Developer' started by Rabiya Ahmed, Jan 4, 2021.

    
Tags:
  1. Rabiya Ahmed

    Rabiya Ahmed New Member


    [#Menu:Gateway of Tally]
    Add: Key Item: At End: Partywise calculation : Y : Display : CAB Ledger List : $$IsInventoryOn:$$CurrentCompany

    [Report: CAB Ledger List]

    Form : CAB Ledger Form
    Title : "Company Ledger List"

    [Form: CAB Ledger Form]

    Use : DSP Template
    Parts : CAB Ledger Part
    Height : 100% screen
    Width : 100% screen
    Background : Grey

    [Part: CAB Ledger Part]

    Lines : CAB Ledger Title, CAB Ledger Line
    Repeat : CAB Ledger Line : CAB My Ledgers
    CommonBorder: Yes
    Scroll : Vertical

    [Line: CAB Ledger Title]

    Use : CAB Ledger Line

    Local : Field : Default : Type : String
    Local : Field : Default : Align : Centre
    Local : Field : Default : Style : Normal Bold

    Local : Field : CAB Led No : Set as : "Sr. No"
    Local : Field : CAB Led Name : Set as : "Ledger Name"
    Local : Field : CAB Led Name : Align : Left
    Local : Field : CAB Led address : Set as : "Deposit"
    Local : Field : CAB Led States : Set as : "Target Sales"
    Local : Field : CAB Led CB : Set as : "Sales Done"
    Local : Field : CAB Led Qualified: Set as : "Qualified or Not"
    Local : Field : CAB Led Cont : Set as : "Incentive 2%"
    Border : Thin Top Bottom

    [Line: CAB Ledger Line]
    Fields : CAB Led No, CAB Led Name, CAB Led Address, CAB Led States, CAB Led CB, CAB Led Qualified, CAB Led Cont
    Option : AlterOnEnter

    [Field: CAB Led No]

    Set as : $$Line
    Width : 5
    Align : Centre
    Border : Thin Right
    Alter : Ledger

    [Field: CAB Led Name]
    ; Use : Name Field
    Set as : $Name
    Full Width: Yes


    [Field: CAB LedAddress]
    Use : Amount forex field
    Set as : $CreditLimit
    Width : 15
    Border : Thin Left Right

    [Field: CAB Led States]
    Use : AMount Forex field
    Set as : @@targetsalesamt
    Storage : TargetAmount
    Width : 15
    Border : Thin Right

    [Field: CAB Led CB]

    Use : Amount forex Field
    Set as : $LedgerSalesTotal ;TBalClosing;$$IsDebit:mad:@PartyNett ;$ClosingBalance:Ledger:mad:@VchPartyname ;@@PartyNett ;#DBCAmount ;$LedgerSalesTotal ;@@PartyClbalance ;$BSDebits ;@@TrDrValue ;@@PartyNett
    Width : 15
    Border : Thin Right

    [System: Formula]
    ForThisParty : $PartyLedgerName = @@ReqObjName

    [Collection: My Sales Vouchers]
    Type : Vouchers : Voucher Type
    Child Of : $$VchTypeSales
    ;Fetch : *.*
    Fetch : PartyLedgerName, LedgerEntries.Amount

    [#Object: Ledger]
    LedgerSalesTotal : $$FilterAmtTotal:MySalesVouchers:ForThisParty:$Amount

    [Field: CAB Led Qualified]
    Use : Name Field
    Set as : @@QualiORNotQuali ;"Qualified"
    Align : Centre
    Width : 15
    Border : Thin Right

    [Field: CAB Led Cont]
    Use : Amount Forex Field
    Set as : If #CABLedQualified="Qualified" then ((@@PartyClbalance*2)/100) else 0
    Width : 15
    Border : Thin Right

    [System : Formulae]
    targetsalesamt : ($CreditLimit*3)
    PartyClbalance : $BSDebits
    QualiORNotQuali: If @@targetsalesamt<=@@PartyClbalance then "Qualified" else ""


    [Collection: CAB My Ledgers]

    Type : Ledger
    Child of : $$GroupSundryDebtors
    Belongs to : Yes
    ;; 'Belongs To' includes the Ledgers pertaining to the subgroups of the group
    ;; mentioned in Attribute 'Child Of'.
    Fetch : *.*
    ;; Fetch attribute required for remoting 2.0

    ;; End-of-File
     
    bharat shah likes this.


  2. Rabiya Ahmed

    Rabiya Ahmed New Member


    In my sales done column, i want to set sales value of party before ledger entries.

    Means only inventryentries value(subtotal)
     


  3. Rabiya Ahmed

    Rabiya Ahmed New Member


    Pls let me know what to do?
     


  4. Rabiya Ahmed

    Rabiya Ahmed New Member


    Dear experts,

    Pls help me in my code!
     


  5. HVPatel

    HVPatel Active Member


    May be this help, refer or try this

    Code:
    [Collection: My Sales Vouchers]
    Type : Vouchers : Voucher Type
    Child Of : $$VchTypeSales
    ;Fetch : *.*
    Fetch : PartyLedgerName, LedgerEntries.Amount
    
    [Collection: My Sales Inventory]
    Source Collection : My Sales Vouchers
    Walk: Inventory Entries
    Fetch : *, *.*
    By: PartyLedgerName: $PartyLedgerName
    Aggr Compute: Amount : Sum: $Amount
    
    may be alternate way available also
    Regards
     
    Jaydeep Shah and bharat shah like this.


  6. Rabiya Ahmed

    Rabiya Ahmed New Member


    Thanks its working
     


  7. bharat shah

    bharat shah Member


    taking alot time to laod .may be formula used is slowing down
     


  8. HVPatel

    HVPatel Active Member


    In Collection Add Below Line, it may solve slow issue

    Code:
    Keep Source: ().
    Regards
     
    Jaydeep Shah and bharat shah like this.


  9. bharat shah

    bharat shah Member


    Patel sir
    i want to filter sales> 5 lakh and hide ledger less than 5 lakh. i tried but getting sell > 5 lakh but ledger lesser are also showing

    Use : Amount forex Field
    Set as :If $LedgerSalesTotal >500000 then $LedgerSalesTotal else " "
    Width : 15
    Border : Thin Right
     


  10. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Make a Filter for the collection...... you are putting the criteria in a Field.
     
    Jaydeep Shah likes this.


  11. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Also you can use ...... Remove if ..... at the Line level.

    Remove if : #CABLedCB < 500000
     
    Jaydeep Shah and bharat shah like this.


  12. bharat shah

    bharat shah Member


    thank you amit sir its working but the code by Mr Rabiya Ahmed is taking alot of time to load
     


  13. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    The Solution to that code --- for faster process ---- is also given above. You must read all the posts and adopt the updates or corrections in the code if any.
     
    Jaydeep Shah and HVPatel like this.


  14. Rabiya Ahmed

    Rabiya Ahmed New Member


    Thanks amit sir , patel sir , bharat sir ....
     
    Last edited: Jan 20, 2021
    HVPatel likes this.


Share This Page