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@LedgerTotal:Base,Symbol,DrCr ; ;=============================== END OF CODE ==================================
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.
Refer to this thread...for a good idea........... http://www.tdlexpert.com/index.php?threads/switch-command-issue.7893/#post-33876 Run this code and see how it works.... you need to implement in the same manner for your project.