Is Enabled hook

Use this hook to disable standard form commands in the session. This hook can use actual values of the form fields.

Example:

function extern boolean function.approve.order.line.is.enabled()
{
|* Check approval against company rules
        if txpurdll0001.can.approve.line(tdpur401.orno, tdpur401.pono) then
                return(true)
        endif
        return(false)
}

Note that this hook applies to standard form commands only that are enabled by the standard application if exactly one record is selected. In that case the extension can disable the command. In case the standard form command allows multiple records being selected, the command remains enabled. In that case, you must use the Before Command hook to skip the processing if required.