Sage 100

 View Only
  • 1.  Customize Library Master panels?

    Posted 03-24-2020 11:21
    Looking for a solution to disable/hide the Delete button on Batch screens?  LM panels can't be customized.  Private batches don't work in this client's case.  Role settings address Merge/Verify/Renumber/Modify but not create/delete. TIA.


    ------------------------------
    Bob Pfahnl
    General Manager - Silicon Valley Office
    DSD Business Systems
    CA
    408-641-0922
    ------------------------------


  • 2.  RE: Customize Library Master panels?

    Posted 03-24-2020 12:00
    Pre-Delete script with a Role check?  I'm not sure where to attach the script though (and what is possible)... it wouldn't help to block deleting the batch header, if the transactions were deleted before that event is triggered.

    ------------------------------
    Kevin Moyes
    Technical Systems Analyst
    Munjal White Consulting Co.
    Toronto ON
    ------------------------------



  • 3.  RE: Customize Library Master panels?

    Posted 03-25-2020 03:15
    I don't think you can attach a script. GL_CompanyActiveBatch (where the batch data is stored) doesn't have a business or a UI object.

    ------------------------------
    Dan Burleson
    Software Consultant
    Connex Software
    Corvallis OR
    541-224-6642
    ------------------------------



  • 4.  RE: Customize Library Master panels?

    Posted 03-25-2020 15:07
    Two options.
    1. DFDM SY_BatchManager.M4L and append "H" to field 21 on all records for BT_Delete.
    2. Create a UI Post Load event script on any other panel and then use DFDM on CM_UIScriptSettings.
      1. Locate the record created.
      2. Modify the library name to "SY_BATCHMANAGER.M4L". Click Yes when prompted to remove the old key.
      3. Modify the panel name to "DBATCHSEL". Click Yes when prompted to remove the old key.
      4. Modify the script accordingly.
        1. At the very least, your script needs to contain the following. 
          1. oScript.SetUIControl "BT_Delete", "Hide"
        2. You can also use a role to determine whether to hide or show the button.
          1. sControlState = "Hide"
            If oSession.IsMember("CanDeleteBatches") = 1 Then sControlState = "Show"
            oScript.SetUIControl "BT_Delete", sControlState
      5. Compile the UI scripts. Make sure to delete the *.M4L.vbs file created when first adding the script to the panel in the very first step.


    ------------------------------
    David Speck II
    Tennessee Software Solutions
    ------------------------------



  • 5.  RE: Customize Library Master panels?

    Posted 03-26-2020 17:37
    @David Speck II Would this change need to be made after every version upgrade?​

    ------------------------------
    Dan Burleson
    Software Consultant
    Connex Software
    Corvallis OR
    541-224-6642
    ------------------------------



  • 6.  RE: Customize Library Master panels?

    Posted 03-26-2020 17:55
    Option 1 where you DFDM SY_BatchManager.M4L likely would require repeating after an upgrade, option however should not unless something/someone deletes the record out of CM_UIScriptSettings.
    Option 2 is my preferred method as it doesn't touch anything that shouldn't be touched and is more flexible because you can control it with scripting to get more advanced results, case in point is being able to leverage roles.

    ------------------------------
    David Speck II
    Tennessee Software Solutions
    ------------------------------



  • 7.  RE: Customize Library Master panels?

    Posted 03-26-2020 19:03
    Thank you David!

    ------------------------------
    Dan Burleson
    Software Consultant
    Connex Software
    Corvallis OR
    541-224-6642
    ------------------------------