No context menu on right-click event in DeltaV Operate pictures

I have several pictures in DeltaV Operate that don't generate a context menu from a right-click with the mouse. Can anyone tell me what could be causing this behavior?

14 Replies

  • The environment protection setting to disable pop up menus  (or scripts) is set. Check these settings in configure mode of operate. Each workstation is configured individually.

     

    Youssef El-Bahtimy | Systems Integration Technologist
    PROCONEX | 103 Enterprise Drive | Royersford, PA 19468 USA
    Proconex Office: 610 495 2970 | Cell: 267 275 7513
    Youssef.El-Bahtimy@ProconexDirect.com

     


  • In reply to Youssef.El-Bahtimy:

    Thanks but I don't think it's a workstation setting. I'm using my workstation and it's only a few pictures that have this problem.

  • In reply to Robert Perry:

    Then you probably have an event configured on those specific pictures to watch for MouseUp/Down events and evaluate that when the right-click is entered all other processing is terminated.

    Look for something like this in each pictures VBA:

    Private Sub CFixPicture_MouseUp(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Double, ByVal Y As Double)

    If Button = fmButtonRight Then

    Exit Sub

    End If

    End Sub

    The context menu is also invoked using Shift+F10 (though in Operate that already seems to be intercepted by other code).  

  • In reply to Youssef.El-Bahtimy:

    Hmmm, I searched the script and there's only one mouse event (i.e MouseDown) on the CFixPicture object and it runs a function called frszCreateAnEPMMenu. I can't find documentation on this function but I found the same code in other pictures where the context menu works. Any other ideas?

  • In reply to Robert Perry:

    What are the arguments to the function in your functioning and non-functioning cases?  I tried putting one in with  "me" as the picobject argument, and that broke my right click for the picture.  My assumption is this is used to create context menus within operate and that in your problem pictures, the first argument is referring to something that does not exist or does not conform to the argument type.  Compare the first argument for functioning/nonfunctioning pictures.

  • In reply to Youssef.El-Bahtimy:

    Private Sub CFixPicture_MouseDown(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Double, ByVal Y As Double)

    On Error GoTo ErrorHandler

       If Button = vbKeyRButton Then

         'Track #36546 - Removed IEPOP1 on : 12/3/01

         frszCreateAnEPMMenu Me

       End If

    Exit Sub

    ErrorHandler:

        frsHandleError

    End Sub

  • In reply to Robert Perry:

    I'm stumped. The code I posted is the same for both the functioning and non-functioning pictures.

  • In reply to Robert Perry:

    Robert,

    I know this is a remedial solution but in the absence of nothing it might become the only solution.

    Is it possible to copy an existing and functioning graphic and rename it (save as:xxx). then do a "Select All" delete everything and go to the non- functioning "Select all" and paste it into the functioning graphic? Make certain to pull the "VariableGroup" object with it...or maybe delete it and replace it with one from a functioning graphic as well.

    regards,

  • In reply to Robert Perry:

    Another possibility is that the non-working pictures have a large object that covers the background so, when you right click, you are clicking on that object and not the background of the CFixPicture object.  For example, instead of changing the background color, someone could have added a large colored rectangle that covers the screen or added a "frame" around the screen using a large rectangle.  Since you said the only mouse event handler  is on CFixPicture, the object that would get the click do nothing with it.

  • In reply to carllemp:

    Since the call checks to see if BUTTON actually = to vbKeyRButton.  Add a msgbox after the IF statement and see if you are even getting to the frszCreateanEPMMenu function.  Maybe your picture is some how blocking the right click because of another selectable field or object.  If you get the msgbox, then you know frszCreatean EPMMenue is being called and we have to get information on that function.

    The function has some checks to verify if the menu should be displayed. There is no menu displayed if there is no user logged on.  What else does this function check?   The call passes "ME" to the function so it is possible there is a property in the picture that determines if the menu appears.  For example, Quick edit is not available on a faceplate, but is on a Main display.  

    If your are invoking a right click that is calling the function, we need to someone to access this hidden procedure to look at what criteria needs to be met.  The function is not documented in BOL.

    Andre Dicaire

  • In reply to Andre Dicaire:

    Hi

    According me, the only condition of the creation of the popup menu structure is conditionned by the "can configure" user rights.

    Popup menu doesn't work with pictures like Trend, Faceplate or Detail  (+FB) .

    On migrated picture, I have also seen some pictures on where the popup menu don't work - I've never found why ...

  • In reply to Jack_France:

    Any news on your issue?  Did you try inserting a trap in the right click function to see if the issue is in the picture and not the FRS procedure?

    Andre Dicaire

  • In reply to Andre Dicaire:

    I inserted the frsMsgBox function, and it did not run on right-click, so it's not the FRS procedure. I've resorted to copying all the objects to a new picture, and this works. I just don't like that solution since I could be leaving behind custom script on certain pictures.
  • I know this is an old post... however there doesn't seem to be resolve.

    Simple Solution:
    In the vba script, find cfixpicture_mousedown sub which contains the right click context menu code and move it to the top of the script page.