Hello Everybody, Some time ago I had downloaded one TDL for Predefined Narrations, Thanks to the Develpor Now, I have added a History facility to that TDL & think that you will find this Useful I am not good in TDL programming, so Experts, pl.do check the modified TDL & advise for any corrections required. The modified TDL provides a) Predefined Standard Narrations (Master) & b) History of used Narrations for the Selected Ledger at the time of payment voucher entry User can select either from Predefined Narration Master Or from History of Narrations given to vouchers of the selected ledger. Further, if required, user can also Add some Additional Part to the Selected Narration OR give a Fresh new narration in the third filed called Month/Period Pl. do report in case of any correction required. Thanks in advance Regards Meher D.Y. Code: /* Shree Ganeyshay Namaha : Shree Kuladevataya namah : Jai Mata Dee : Jai Shree Krishna TDL : To Display Narration History of Selected Ledger while Voucher Entry (for payment vouchers only) : To Display PreDifined Narrations for Selection & Auto Narration Entry By : Meher D.Y. : AutoNarration TDL downloaded, now Enhanced with Voucher Narration History feature Date : 03/03/16 */ ;;;==================================================================================================== [#Part : VCH Narration] Option : MS VCHNarrHistory : @@IsPayment [!Part : MS VCHNarrHistory] Add : Line : AtEnd : MS VCHNarrHistory [Line : MS VCHNarrHistory] Field : Medium Prompt,MS VCHNarrHistory Local : Field : Medium Prompt : Info : If $$InCreateMode Then "Narration History :" Else "" Local : Field : Medium Prompt : Width : 15% Page [Field : MS VCHNarrHistory] Use : Name Field Set as : $$Value Storage : MSVCHNarrHistory Style : Normal Width : 46 Invisible : Not($$InCreateMode) Skip : Not($$InCreateMode) Table : NarrHistoryColl,endoflist ShowTable : Always Key : Narration ;--------------------------------- [#Part : VCH Narration] Option : MS VCHNarrTemp : @@IsPayment [!Part : MS VCHNarrTemp] Add : Line : AtEnd : MS VCHNarrTemp [Line : MS VCHNarrTemp] Field : Medium Prompt,MS VCHNarrTemp Local : Field : Medium Prompt : Info : If $$InCreateMode Then "Master Narrations :" Else "" Local : Field : Medium Prompt : Width : 15% Page [Field : MS VCHNarrTemp] Use : Name Field Set as : $$Value Storage : MSVCHNarrTemp Style : Normal Width : 42 Invisible : Not($$InCreateMode) Skip : Not($$InCreateMode) ;OR Not ($$IsEndOfList:#MSVCHNarrHistory) Table : MyNarrationCollection,endoflist ShowTable : Always Key : Narration ;--------------------------------- [#Part: VCH Narration] Option : MS VCHNarrMonth : @@IsPayment [!Part : MS VCHNarrMonth] Add : Line : AtEnd : MS VCHNarrMonth [Line : MS VCHNarrMonth] Field : Medium Prompt,MS VCHNarrMonth Local : Field : Medium Prompt :Info : If $$InCreateMode Then "Add Month/Period :" Else "" Local : Field : Medium Prompt :Width : 15% Page [Field : MS VCHNarrMonth] Use : Name Field Set as : $$Value ;If $$InCreateMode Then $MSVCHNarrMonth Else "" Storage : MSVCHNarrMonth Style : Normal Max : 30 Width : 30 Invisible : Not($$InCreateMode) Skip : Not($$InCreateMode) Control : NarrControl : @@NarBoth ;;;==================================================================================================== [System : Formula] NarHst : IF $$IsEndOfList:#MSVCHNarrHistory Then "" Else #MSVCHNarrHistory NarTmp : IF $$IsEndOfList:#MSVCHNarrTemp Then "" Else #MSVCHNarrTemp NarMth : IF $$IsEmpty:#MSVCHNarrMonth Then "" Else #MSVCHNarrMonth NarBoth : If (Not $$IsEndOfList:#MSVCHNarrHistory AND Not $$IsEndOfList:#MSVCHNarrTemp) Then "Yes" Else "No" NarCombine : If ($$IsEndOfList:#MSVCHNarrHistory AND $$IsEndOfList:#MSVCHNarrTemp) Then @@NarMth Else If Not $$IsEmpty:#MSVCHNarrMonth Then (@@NarHst + @@NarTmp + " - " + @@NarMth) Else (@@NarHst + @@NarTmp) NarrControl : "Both Narrations Selected!!" + $$NewLine + $$NewLine + "Select Only One Narration" ;;;==================================================================================================== [#Field: VCH Narration] Use : Voucher Narration Field Lines : 2 Storage : Narration Set as : If $$InCreateMode Then @@NarCombine Else $Narration Width : 50% Screen Key : PrevVchNarration, PrevLedNarration Set Always : Yes ;;;==================================================================================================== [#Menu: Accounts Info.] Add : Item : after : @@locCostCentres : Narration : alter : CMP NarrationReport [#Part: CMP AccFeat Left] Add : Line : CMP EnablePortDestTable [Line: CMP EnablePortDestTable] Field : Medium Prompt, CMPEnableNarrationTable Local : Field : Medium Prompt : Info : "Enable Predefined Narration ? " Space Top : 1 [Field: CMPEnableNarrationTable] Use : Logical Field Storage : Enableprenarration Set as : If $$IsEmpty:$$Value then "No" else $$Value ;;;-------------------------------------- [Report: CMP NarrationReport] Form : CMP NarrationForm Object : company [Form: CMP NarrationForm] Part : CMP Narration PartTitle, CMP Narration PartDetails [Part: CMP Narration PartTitle] Line : CMP Narration LineTitle Border : thin bottom [Line: CMP Narration LineTitle] Field : Long Prompt Local : Field : Long Prompt : Style : Normal Bold Local : Field : Long Prompt : Info : "Enter Your Master Narrations" Local : Field : Long Prompt : Width : 100% Screen Local : Field : Long Prompt : Align : Center [Part: CMP Narration PartDetails] Line : narration title,CMP Narration LineDetails Repeat : CMP Narration LineDetails : MydbNarration BreakOn : $$IsEmpty:$PreNarration Width : 100% Screen Scroll : Vertical CommonBorder: Yes [Line:narration title] Fields : srno,narration title Border : thin bottom [Field:srno] Use : MultiSNo Title Width : 6 [Field:narration title] Set as : "Standard Predefined Narrations" Style : Normal Bold Align : Center [Line: CMP Narration LineDetails] Field : number,CMP Narration NameField [Field:number] Use : Multi SNo Width : 5 Style : Normal Align : Center [Field: CMP Narration NameField] Use : Short Name Field Storage : PreNarration Style : Normal Border : Thin Left Width : 100% Screen Lines : 1 Max : 36 ;;;==================================================================================================== [Collection: MyNarrationCollection] Type : MydbNarration: Company Childof : ##SVCurrentCompany Format : $PreNarration,36 Title : Predifined Narrations Sort : Default : $PreNarration ;;;-------------------------------------- [Collection : NarrHistoryColl] Type : Vouchers : Ledger Child Of : @@Children Filter : VchTypeFilt Format : $Narration,46 Title : Narration History of Selected Ledger & Voucher Fetch : Narration Sort : Default : $Narration ;;;-------------------------------------- [System : Formula] Children : If Not $$IsEmpty:$$BaseOwner:#ACLSLed Then $$BaseOwner:#ACLSLed Else $$BaseOwner:#VCHParticulars VchTypeFilt : $VoucherTypeName = ##SVVOUCHERTYPE ;;;==================================================================================================== [Key : narration] Key : ALT + C Action: Alter : CMP NarrationReport ;;;==================================================================================================== [System: UDF] Enableprenarration : Logical : 30033 MydbNarration : Aggregate : 30003 PreNarration : String : 3123 ;;;====================================================================================================
Dear All, I have further Enhanced the above code with a Filter facility to get only those Narrations which are Predefined for Selected Ledger only. To Filter All Predefined Narrations of a Ledger, I have added one column in which we need to give a Short Name of that Ledger (in three characters) e.g. i) use short name "TEL" for Telephone Expenses Ledger & use it for every Predefined Narration which you wanted to Populate in Table when Telephone Ledger is selected. ii) The same "TEL" is required to be Put in Telephone Expenses Ledger Master - in Ledger Note field also. Hope, you all will find this Useful. Pl. do report in case of any corrections required. Regards Meher D.Y. Code: /* Shree Ganeyshay Namaha : Shree Kuladevataya namah : Jai Mata Dee : Jai Shree Krishna TDL : To Display Narration History of Selected Ledger while Voucher Entry (for payment vouchers only) : To Display PreDifined Narrations for Selection & Auto Narration Entry By : Meher D.Y. : AutoNarration TDL downloaded, now Enhanced with Voucher Narration History + Ledger Filter feature Date : 21/03/16 */ ;;;==================================================================================================== [#Part : VCH Narration] Option : MS VCHNarrHistory : @@IsPayment [!Part : MS VCHNarrHistory] Add : Line : AtEnd : MS VCHNarrHistory [Line : MS VCHNarrHistory] Field : Medium Prompt,MS VCHNarrHistory Local : Field : Medium Prompt : Info : If $$InCreateMode Then "Narration History :" Else "" Local : Field : Medium Prompt : Width : 15% Page [Field : MS VCHNarrHistory] Use : Name Field Set as : $$Value Storage : MSVCHNarrHistory Style : Normal Width : 46 Invisible : Not($$InCreateMode) Skip : Not($$InCreateMode) Table : NarrHistoryColl,endoflist ShowTable : Always Key : Narration ;--------------------------------- [#Part : VCH Narration] Option : MS VCHNarrTemp : @@IsPayment [!Part : MS VCHNarrTemp] Add : Line : AtEnd : MS VCHNarrTemp [Line : MS VCHNarrTemp] Field : Medium Prompt,MS VCHNarrTemp Local : Field : Medium Prompt : Info : If $$InCreateMode Then "Master Narrations :" Else "" Local : Field : Medium Prompt : Width : 15% Page [Field : MS VCHNarrTemp] Use : Name Field Set as : $$Value Storage : MSVCHNarrTemp Style : Normal Width : 42 Invisible : Not($$InCreateMode) Skip : Not($$InCreateMode) Table : MyNarrationCollection,endoflist ShowTable : Always Key : Narration ;--------------------------------- [#Part: VCH Narration] Option : MS VCHNarrMonth : @@IsPayment [!Part : MS VCHNarrMonth] Add : Line : AtEnd : MS VCHNarrMonth [Line : MS VCHNarrMonth] Field : Medium Prompt,MS VCHNarrMonth Local : Field : Medium Prompt :Info : If $$InCreateMode Then "Add Month/Period :" Else "" Local : Field : Medium Prompt :Width : 15% Page [Field : MS VCHNarrMonth] Use : Name Field Set as : $$Value ;If $$InCreateMode Then $MSVCHNarrMonth Else "" Storage : MSVCHNarrMonth Style : Normal Max : 30 Width : 30 Invisible : Not($$InCreateMode) Skip : Not($$InCreateMode) Control : NarrControl : @@NarBoth ;;;==================================================================================================== [System : Formula] NarHst : IF $$IsEndOfList:#MSVCHNarrHistory Then "" Else #MSVCHNarrHistory NarTmp : IF $$IsEndOfList:#MSVCHNarrTemp Then "" Else #MSVCHNarrTemp NarMth : IF $$IsEmpty:#MSVCHNarrMonth Then "" Else #MSVCHNarrMonth NarBoth : If (Not $$IsEndOfList:#MSVCHNarrHistory AND Not $$IsEndOfList:#MSVCHNarrTemp) Then "Yes" Else "No" NarCombine : If ($$IsEndOfList:#MSVCHNarrHistory AND $$IsEndOfList:#MSVCHNarrTemp) Then @@NarMth Else If Not $$IsEmpty:#MSVCHNarrMonth Then (@@NarHst + @@NarTmp + " - " + @@NarMth) Else (@@NarHst + @@NarTmp) NarrControl : "Both Narrations Selected!!" + $$NewLine + $$NewLine + "Select Only One Narration" ;;;==================================================================================================== [#Field: VCH Narration] Use : Voucher Narration Field Lines : 2 Storage : Narration Set as : If $$InCreateMode Then @@NarCombine Else $Narration Width : 50% Screen Key : PrevVchNarration, PrevLedNarration Set Always : Yes ;;;==================================================================================================== [#Menu: Accounts Info.] Add : Item : after : @@locCostCentres : Narration : alter : CMP NarrationReport [#Part: CMP AccFeat Left] Add : Line : CMP EnablePortDestTable [Line: CMP EnablePortDestTable] Field : Medium Prompt, CMPEnableNarrationTable Local : Field : Medium Prompt : Info : "Enable Predefined Narration ? " Space Top : 1 [Field: CMPEnableNarrationTable] Use : Logical Field Storage : Enableprenarration Set as : If $$IsEmpty:$$Value then "No" else $$Value ;;;-------------------------------------- [Report: CMP NarrationReport] Form : CMP NarrationForm Object : company [Form: CMP NarrationForm] Part : CMP Narration PartTitle, CMP Narration PartDetails [Part: CMP Narration PartTitle] Line : CMP Narration LineTitle Border : thin bottom [Line: CMP Narration LineTitle] Field : Long Prompt Local : Field : Long Prompt : Style : Normal Bold Local : Field : Long Prompt : Info : "Enter Your Master Narrations" Local : Field : Long Prompt : Width : 60% Screen Local : Field : Long Prompt : Align : Center [Part: CMP Narration PartDetails] Line : narration title,CMP Narration LineDetails Repeat : CMP Narration LineDetails : MydbNarration BreakOn : $$IsEmpty:$PreNarration Height : 33 Width : 60% Screen Scroll : Vertical CommonBorder: Yes [Line:narration title] Fields : srno,narration title Border : thin bottom [Field:srno] Use : MultiSNo Title Width : 6 [Field:narration title] Set as : "For Ledger Standard Predefined Narrations" Style : Normal Bold Align : Center [Line: CMP Narration LineDetails] Field : number, CMP ForLedgerField, CMP Narration NameField [Field:number] Use : Multi SNo Width : 6 Style : Normal Align : Center [Field: CMP ForLedgerField] Use : Short Name Field Storage : ForLedger Style : Normal Align : Center Border : Thin Left Width : 12% Screen Lines : 1 Max : 3 [Field: CMP Narration NameField] Use : Short Name Field Storage : PreNarration Style : Normal Border : Thin Left Width : 51% Screen Lines : 1 Max : 36 ;;;==================================================================================================== [Collection: MyNarrationCollection] Type : MydbNarration: Company Childof : ##SVCurrentCompany Filter : ForLedgerFilt ;New entry for Ledger Filter Format : $PreNarration,36 Title : Predifined Narrations Sort : Default : $PreNarration ;;;-------------------------------------- [Collection : NarrHistoryColl] Type : Vouchers : Ledger Child Of : @@Children Filter : VchTypeFilt Format : $Narration,46 Title : Narration History of Selected Ledger & Voucher Fetch : Narration Sort : Default : $Narration ;;;-------------------------------------- [System : Formula] Children : If Not $$IsEmpty:$$BaseOwner:#ACLSLed Then $$BaseOwner:#ACLSLed Else $$BaseOwner:#VCHParticulars VchTypeFilt : $VoucherTypeName = ##SVVOUCHERTYPE ; ;New entry for Ledger Filter ForLedgerFilt : $$StringPart:$ForLedger:0:3 = $$StringPart:($Narration:ledger:#ACLSLed):0:3 ; Set Notes in Ledger Master & ForLedger-Filter in Narration-Table accordingly ;;;==================================================================================================== [Key : narration] Key : ALT + C Action: Alter : CMP NarrationReport ;;;==================================================================================================== [System: UDF] Enableprenarration : Logical : 30033 MydbNarration : Aggregate : 30003 PreNarration : String : 3123 ForLedger : String : 3124 ;New entry for Ledger Filter ;;;====================================================================================================
Good Code, But Above code is working in only Payment Voucher. It not work in Receipt, Journal, Contra, etc. Please Check Modify.
dip_jal you can change voucher option as : Option : MS VCHNarrHistory : @@IsPayment OR @@IsReceipt OR @@IsContra etc as required so it will work with that voucher.
Hi , its great programme but i coudnt get the master Narration Details when I press ALT+C there are 2 fields ( For Ledger ....its only allowing 3 letters) how to use this field Thanks
Sorry, I could not upload the screenshots but I will explain you as The "FOR LEDGER" field is given to Filter value (on which you want to filter the various Narrations) in Master Narration Database, It is set to 3 letters. The same 3 letters you have to use in "LEDGER MASTER's NOTES" field. e.g. you have various phones & want to give phone no. as Narration in Payment Voucher, so First - Go to Telephone Expenses Ledger - Go to "NOTES" field (check Notes are enabled) - Give"TEL" as 3 letter unique short name for filter purpose Then - Go to Master Narration Database - in "FOR LEDGER" field - use "TEL" as 3 letter unique short name to filter each Telephone no. you are going to add as Master Narration At the time of Payment Voucher entry - when you select Telephone Expenses ledger - then the "Master Narrations" field will populate only those Narrations (i.e.Telephone nos.) for which you have given "TEL" as unique short name in "FOR LEDGER" By this logic for other ledgers also you can give 3 letter unique short name as a filter & use the same in Master Narration database while storing various narrations you want to use for that Specific Ledger. Hope, I have explained enough to understand the concept Thanks & Regards Meher D.Y.
Dear Sir, Idea is Great Here i found some problem Master narration Area its creation ok but its not pick to voucher and its not showing list of master narrations in voucher please find and Master narration width also less need to increase
DEAR SIR , I HAVE ADDED SALES, BUT STILL NOT WORKING, NARRATION HISTORY , PREDEFINED NARRATION NOT COMING, SO PLEASE MODIFY YOUR CODES FOR SALES & PURCHASE VOUCHER AS IS NEEDED OFFENLY AS WE HAE MENTION IN EACH SALES VOUCHER "CASH DISCOUNT 2.5% IF PAYMENT MADE WITHIN 7 DAYS.
DEAR SIR , I HAVE ADDED SALES, BUT STILL NOT WORKING, NARRATION HISTORY , PREDEFINED NARRATION NOT COMING, SO PLEASE MODIFY YOUR CODES FOR SALES & PURCHASE VOUCHER AS IS NEEDED OFFENLY AS WE HAE MENTION IN EACH SALES VOUCHER "CASH DISCOUNT 2.5% IF PAYMENT MADE WITHIN 7 DAYS.