Want to disable delete option from day book for the verified entries

Discussion in 'Requests' started by Damodaran, Apr 27, 2020.

    
  1. Damodaran

    Damodaran New Member


    I tried to disable the delete and cancel option for the verified voucher (udf at voucher level) , it is working inside of voucher but, unable to control when it is deleted from daybook or ledger vouchers report:

    Code:
    [#Part: VoucherNarr]
    Add :Line  : after:Vch Narration :VerifyDetails
    
    [Line : VerifyDetails]
      Add:  Left Fields : VerifyDetails
    
    
    
    [Field  : VerifyDetails
      Use :   Short Name Field
      Storage : VerifyDetails
      ;Read Only:  Yes
    
    [system : UDF]
    
        VerifyDetails    :    string    :    1012
    
    
    
    [#Form: Voucher]
    
    Add   : Option : User Voucher : Not $$IsEmpty:$VerifyDetails
    
    [!Form: User Voucher]
    
    
    Local   : Button  : BottomToolBarBtn3_Delete  : Inactive  : Not $$IsEmpty:$VerifyDetails
    Local   : Button  : BottomToolBarBtn4_Cancel  : Inactive  : Not $$IsEmpty:$VerifyDetails
    
    
    [#Key: BottomToolBarBtn4]
        Add   : Option :User Vouchera2 : Not $$IsEmpty:$VerifyDetails
      
    [!Key: UserVouchera2]
        Inactive: Yes
    
    
    [#Key: BottomToolBarBtn3]
        Add   : Option :User Vouchera1 : Not $$IsEmpty:$VerifyDetails
      
    [!Key: UserVouchera1]
        Inactive:    Yes
     
    Last edited: Apr 28, 2020
    Sanjeev S likes this.


  2. Sanjeev S

    Sanjeev S Active Member


    Good Concept.

    Select and Delete actions seems to be Tally controlled. To me simplest way can be providing control to admin.

    Can this work?

    [#Key: BottomToolBarBtn4]
    Inactive : not $$IsCmpOwner

    [#Key: BottomToolBarBtn3]
    Inactive : not $$IsCmpOwner
     



  3. Try This...



    Code:
    ;----------------------------------------------------------Voucher Deletetion---------------------------------------------------------------;
    
    [#Button    : BottomToolBarBtn3_Delete]
      
        Option    : DeleteLineKey    : Not $$IsCmpOwner
              
    [#Key    : BottomToolBarBtn3]
          
        Option    : DeleteLineKey    : Not $$IsCmpOwner
              
    [!Key    : DeleteLineKey]
      
        Inactive    : Not $$IsCmpOwner
      
    [#Key: Delete Line Object]
          
        Option    : InactiveLineKey    : Not $$IsCmpOwner
      
    ;---------------------------------------------------CancelButton Cantrol-----------------------------------------------------------------;
    
    [#Button    : BottomToolBarBtn4_Cancel]
      
        Option    : ButtonInactCancel    : Not $$IsCmpOwner
      
    [#Key: BottomToolBarBtn4]
      
        Option    : ButtonInactCancel    : Not $$IsCmpOwner
      
    [!Key    : ButtonInactCancel]
      
        Inactive    : Not $$IsCmpOwner
      
    [#Key: Cancel Line Object]
      
        Option    : InactiveLineKey    : Not $$IsCmpOwner
          
    [!Key    : InactiveLineKey]
          
        Delete    : Key
     
    advancedjitender likes this.


  4. jgkumar1976

    jgkumar1976 Member


    not working,,


    @Damodaran asked for
    while focus on verified voucher line Delete button and cancel button will be disabled
     


  5. Damodaran

    Damodaran New Member


    Can anyone help me on this?
     


Share This Page