To Show Petty Cash Balance on Gateway of Tally

Discussion in 'Tally Developer' started by naren1234, Jul 20, 2020.

    
  1. naren1234

    naren1234 Member


    Dear Experts,

    Currently, there are two petty-cash ledgers maintained in tally, named "Petty Cash Loc-1" and "Petty Cash Loc-2"

    I want to show CURRENT cash balance (ledger wise) on Gateway of Tally.
    So, even if the user has selected a previous period / previous financial years, he can still goto Gateway-of-Tally to check, and it will show only the Current Balance/s (i.e. cash balances as of "Date of Last Entry")
    Say for example, date of last entry in the Books is 23-July-2020, and period (Alt-F2) selected is From: 1-Apr-2015 To: 31-Mar-2016, I still want Gateway of Tally Screen to show Cash Balance as of 23-July-2020.

    I have put together below code but, it's Not working. Can you please help me fix the code?

    ;==============================================================================
    ;Display ALL Cash Ledgers Current Balance on Gateway of Tally
    ;
    ;To show balance as of Current Date (i.e. Date of Last Entry)
    ;IRRESPECTIVE OF the period / financial-year being selected.
    ;
    ;Blue Font, Standard (used)
    ;Red Font, if Negative Cash Balance
    ;==============================================================================

    [#Menu: Gateway of Tally]
    Add: Item: Before: ~Quit: Cash Balance: Field: myCashBal ;Display on top
    ;Add: Item: After : @@locMultiAccPrinting : Cash Balance : Field: myCashBal ;Dispaly at bottom

    [Field: myCashBal]
    Repeat: MyCashLedgers, MyCashLedColl
    Color: Blue

    [Line: MyCashLedgers]
    Field: MyCashLedgers, CurrBal

    [Field: MyCashLedgers]
    Use: Name Field
    Set As: $Name

    [Field: CurrBal]
    Use : Amount Field
    Set As : $LedgerTotal ;LedgerTotal ;Not sure if LedgerTotal = Curr Balance
    Color: IF $$IsCr:$LedgerTotal then Red Else Blue

    [Collection : MyCashLedColl]
    Type : Ledger
    Child of : $$GroupCash
    Belongsto : yes
    Fetch : Name ,LedgerTotal ;Not sure if LedgerTotal = Curr Balance
    ;Fetch : Name ,ClosingBalance ; Don't want Closing Bal of selected period, instead show Curr Bal as of Last Entry Date in the Books

    -------------------------------------------------------------------------------
    ;In case there is single cash ledger
    ;(Below Code is Not used and Not Updated)
    ;[Line: myCashLedgerCurrBal]
    ;Fields: Simple Prompt, CashCurBalance
    ;Local: Field: Simple Prompt: Set as: "Cash Balance: Rs. "
    ;Local: Field: CashCurBalance: Set As: $$String:mad:@LedgerTotal:Base,Symbol,DrCr
    ;
    ;=============================== END OF CODE ==================================
     


  2. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    When you are making a new MENU item...it will go to a Report and not to a FIELD...........

    You have to make a report first, Form, Part, Line and then your Field will come.
     


  3. Amit Kamdar

    Amit Kamdar Administrator Staff Member



Share This Page