Hiding or Disabling Function Buttons




  • Official comment
    Naama Aharoni

    Hi Michael,

    It is possible to disable to hide function buttons using Hide() (hiding the item from the screen) and Disable() (setting the item in grey) commands. The SQL part needs to be inserted into the SQL Condition section in your validation. If this is not working for you then please check your SQL by replacing the macro Universal Function results to a message type Universal Function and see where the problem is.

    Thanks, Naama

  • Avatar
    Michael Herrmann

    Hi Naama:

    Thanks for your quick response. I've tried to add to the SQL condition, but am still having a problem. Within the "Button Configuration" window the function button in question has a "Function" of "Universal Function" and the button's "Item Uid"="BOY_99_1". The functionality I've attached to this button works as expected.

    I added the DISABLE command to the "SQL Condition" of my Validation Configuration. The Validation Configuration Configuration is on "Data Load" Event of the Item Master (form 150). My SQL condition is as follows:

    IF (LEN(ISNULL($[$186.0.0],'')))!=0 DISABLE(BOY_99_1)

    I believe I've tried every syntax version against "BOY_99_1" in the above (e.g. $[$BOY_99_1.0.0], $[BOY_99_1.0.0], etc.)

    Thanks, Mike

  • Avatar
    Naama Aharoni

    Hi Mike,

    A tip to check a validation is to replace the result (the macro UF with the disable command) with a message UF.
    The you know if your condition is correct.
    If the message is displayed at the right moment then your condition and trigger are both correct and the problem is with the macro. If not, then you need to correct the confition. To check if your trigger is correct, you can set the condition to “No Condition” and set the message function in the result of that “No Condition”.

    Please remember to set a validation to show that button when it needs to be shown. You can look at the following example:

    Thanks, Naama

  • Avatar
    David Erkelius

    Hi, I want to hide/disable some functions buttons depending on a value of a field. Cant get it to work. This post was the only information I found about it. Is it possible to do? I have the same problem as Mike with:

    "I believe I've tried every syntax version against "BOY_99_1" in the above (e.g. $[$BOY_99_1.0.0], $[BOY_99_1.0.0], etc.)"

    I get the Trigger to work when I am making a coditiontest with a message

    The link Naama refer to above doesnt work



  • Avatar
    Yaremi Miranda Lopez

    Hello David,


    Here is the example, I just validated the link:


    If you get the trigget to work, then the problem is in your Macro, be careful with the Dynamic Syntax you're using. Here is a guide to know more about this: https://support.boyum-it.com/hc/en-us/articles/204284188-Guide-Understanding-Dynamic-Syntax


Please sign in to leave a comment.