How to assign default voucher class for a user without option to choose

Discussion in 'Tally Developer' started by Pilla Kishore Kumar, Dec 2, 2013.

         
  1. Pilla Kishore Kumar

    Pilla Kishore Kumar New Member


    When assigning a voucher class to a voucher type, the user has an option to choose the voucher class or he can opt for "Not Applicable". How to make it default for the specific user without any option? Please advise on how to do it.
     


  2. Maulik Patel

    Maulik Patel Active Member


    for which voucher type?
     


  3. Pilla Kishore Kumar

    Pilla Kishore Kumar New Member


    Dear Maulik,

    It could be any voucher type. An existing default voucher type like receipt, payment etc or a new voucher type created by the user. When you try to enter any voucher, say like sales, it will prompt to select voucher class (Provided you configured the assigned voucher class for this voucher type). So now the question is how assign a default voucher class to the specific voucher type without giving any options. Try this and then come back please.
     


  4. Maulik Patel

    Maulik Patel Active Member


    Then you need to modify each and every like below for each voucher type

    [#Report: Order Voucher]
    Option : OptSO : $$IsSalesOrder:##SVVoucherType
    Option : Opt PO : $$IsPurcOrder:##SVVoucherType

    [Report : OptSO]
    Set : ClassName : <Default Class Name for Sales Order>

    [Report : OptPO]
    Set : ClassName : <Default Class Name for Purchase Order>
     


  5. Pilla Kishore Kumar

    Pilla Kishore Kumar New Member


    Thank you. What to do, if I have multiple voucher types under same category. How to define the options?

    1) Sales
    2) Kishore Sales
    3) Discounted Sales
     


  6. Maulik Patel

    Maulik Patel Active Member


    Then

    Add : Option : OptSI1 : $VoucherTypeName = "Sales"
    Add : Option : OptSI2: $VoucherTypeName = "Kishore Sales"
    Add : Option : OptSI3: $VoucherTypeName = "Discounted Sales"

    But if user will modify voucher type name from voucher type master then it will not work.
     


  7. Pilla Kishore Kumar

    Pilla Kishore Kumar New Member


    Suppose if I want to assign the voucher type "Kishore Sales" to a user by name "Kishore", How to set it in the Option

    We have already assigned the default voucher class to the Voucher type. But the user has option to select other voucher types too in the same category. So how to assign it. I mean, when he click on "Receipt" on the right panel, basing on his user name, the assigned voucher type should come with assigned default voucher class.
     


  8. Maulik Patel

    Maulik Patel Active Member


    Add : Option : OptSI2: $VoucherTypeName = "Kishore Sales" AND $$CmpUserName
     


  9. Pilla Kishore Kumar

    Pilla Kishore Kumar New Member


    I need something like this. Please correct it.

    [#Report: Order Voucher]
    Add : Option : OptSI1: $$CmpUserName = "Kishore" And $$IsReceipt:##SVVoucherType

    [Report : OptSI1]

    Set : VoucherTypeName : KK Receipt
    Set : ClassName : Kkrcpt
     
    Basha likes this.


  10. Vijaya Kumar

    Vijaya Kumar New Member


    I too need something like this. for both creation and changing the voucher thru (f7 or f8key)

    Service Invoice Voucher Type => Default Service Class
    Sales Invoice Voucher Type => Default Sales Class
    Warranty Invoice Voucher Type => Default Warranty Class

    Service Order Voucher Type => Default Service Class
    Sales Order Voucher Type => Default Sales Class
    Warranty Order Voucher Type => Default Warranty Class
     


  11. PeaceOfMind

    PeaceOfMind New Member


    it will be better if you assign user wise > voucher type wise > default class selection.
    <new aggregate collection>.
    then, in the voucher, you can select from the above list. it will be easier both for you and your user.
     


  12. Pilla Kishore Kumar

    Pilla Kishore Kumar New Member


    Mr. Maulik,

    Waiting for your response.
     


  13. Maulik Patel

    Maulik Patel Active Member


    Dear Mr. Pilla Kishore Kumar,

    First of all let me clear you that Order Voucher is used only for Sales Order and Purchase Order. It is not used for accounting voucher. Accounting Voucher report is used for accounting voucher.

    [#Report: Accounting Voucher]
    Add : Option : OptSI: $$IsReceipt:$VoucherTypeName

    [!Report : OptSI]
    Set : SVVoucherType : IF $$CmpUserName = "Kishore" Then "KK Receipt" Else $$VchTypeReceipt
    Set : SVClass : IF $$CmpUserName = "Kishore" Then "Kkrcpt" Else $$SysName:NotApplicable
     


  14. Taufeeq Shaikh

    Taufeeq Shaikh Active Member


    Mr. Pillai Try this . It is same concept but the method is different

    [#Form: Receipt Color]

    Add : Control : NotAllowed : $$FilterCount:AllLedgerEntries:Username < 1


    [System: Formula]


    UserName : ($$CmpUserName = "TRS" AND $$IsReceipt:$VoucherTypeName And @@TRSDebited) OR +
    ($$CmpUserName = "RMD" AND $$IsReceipt:$VoucherTypeName And @@RMDDebited)
    TRSDebited: $$IsDr:$Amount AND $LedgerName = "Sanat M. Jani - Stores"
    RMDDebited: $$IsDr:$Amount AND $LedgerName = "CASH"
    NoTAllowed : $$LocaleString:" You are Not Authorized for this Ledger "
     


  15. Pilla Kishore Kumar

    Pilla Kishore Kumar New Member


    Dear Maulik,

    I tried the new code but it is not working. I feel that this logic should be applied to the button action (F6).

    Because finally after logging as the user, and then going for voucher entries and clicking on F6 for Receipt, it is asking option to select required voucher type under "RECEIPT" and same thing is happening for voucher class too.
     
    Ras Raj likes this.


  16. V Shankar

    V Shankar New Member


    Hi Sir,


    i need some help from you to fix this issue in tdl. I wanted to print two different Invoice Printing TDL by Voucher Class wise :
    Ex: if i select "VAT" voucher Class Its Should print VAT Invoice format else its should print the Other Format

    [#form :sales color]
    delete :print
    print : NPL INVOICE

    [report :NPL INVOICE]
    object :voucher
    filtered: yes
    form : NPL INVOICE


    [form :NPL INVOICE]
    width : 200 mms
    Height : 265 mms
    space left : 10 mms
    space right : 10 mms
    space top :45 mms
    space bottom : 5 mms
    horizontal align :center
    Option : NPL INVOICE : $Classname = "VAT"
    Option : NPL INVOICE : $$isEmpty : $Classname

    pls help me
     


  17. Amit Kamdar

    Amit Kamdar Administrator Staff Member


    Should be like this.........


    Option : NPL INVOICE1 : $Classname = "VAT"
    Option : NPL INVOICE 2 : $Classname != "VAT"
     


  18. V Shankar

    V Shankar New Member



Share This Page