Home Image-Pro Automation (Macros, Apps, Reports)

INTERACTIVE MODE and PROMPTS . . .

All --

I have an application up and running for a PREMIER 9.2 customer with 3 PREMIERs replacing 3 PLUSs.

They are doing an analysis hundreds of times per day and they are very sensitive to issues with the USER INTERFACE that slow them down.

There are a couple of places where I have the application using PREMIER TOOLS in the INTERACTIVE MODE with PROMPT BOXES showing with specific instructions and waiting for them to press OK within the PROMPT BOX before the application will continue.

Functionally flows properly but they seem to have to hunt for the PROMPT BOX and aim carefully with the mouse to hit the OK BUTTON.

It seems that the PROMPT BOX does not always appear on the same MONITOR as PREMIER (when they have PREMIER on a SECONDARY MONITOR)

They would prefer if it could be set in a clear portion of the screen because it blends into the TITLE BARS.  Also, is there a way to increase the size of the PROMPT TEXT and the OK and CANCEL BUTTONS.  These are rather small on their monitors.

Other than the actual PROMPT TEXT, does an application (at DESIGN TIME or RUN TIME) have any other control of the PROMPT BOX?

Is there a way to set a KEYBOARD BUTTON or a FUNCTION KEY to trigger the OK within an INTERACTIVE PROMPT?

Thanks.

-- Matt

Best Answer

  • Answer ✓
    You are right it doesn't appear in the documentation, I'll file a bug on that. The names are self explanatory though.

    Pierre

Answers

  • Hi Matt,

    The key to trigger the OK would be Enter. Otherwise, there is no easy way to chnage the size of the pompt however what you can do is chnage its position so that instead of being over the ribbon it sits on top of the image. See example below.

    Pierre
            With [Select].RoiCommands.Add(NewMacro3)
                .Points = New System.Collections.Generic.List(Of System.Drawing.PointF)
                .Points.Add(New System.Drawing.PointF(166F,167F))
                .Points.Add(New System.Drawing.PointF(395F,338F))
                .Angle = 0R
                .Image = .GetImage("View.NDView.AddElement")
                .ROIType = Features.ROI.ROITypes.Rectangle
                .Interactive = True
                .InteractionLocation =McCommand.InteractionPosition.OutsideBottom
                .Run(image1)
            End With
    
  • Pierre --

    Thank you for the response.

    The ENTER works when the PROMPT has the FOCUS (immediately after the COMMAND runs) but if the user has interacted with the TOOL or the IMAGE it seems the FOCUS shifts away from the PROMPT.  That seems to force the use of the mouse to get back to the PROMPT or the OK within the PROMPT.

    I will review the options available with the
    .InteractionLocation = McCommand.InteractionPosition.OutsideBottom 
    property with the user and see if they resolve the issue.

    A quick search of IMAGE-PRO PREMIER AUTOMATION HELP does not show the options for
    InteractionPosition
    These may be shown in the PROJECT WORKBENCH after I press the "." but is there a listing of these elsewhere?

    Thanks again.

    -- Matt
  • edited July 2016
    Pierre --

    I added

    .InteractionLocation = McCommand.InteractionPosition.OutsideBottom

    to the PROJECT and the position of the PROMPT did not change significantly. 

    The JPG IMAGE FILE below and attached shows the PROMPT without and with the .INTERACTIONLOCATION property in the code.

    The section of code that I'm working with is:

                            'Allow the user to ROTATE and TRANSLATE the image a pixels over the image b pixels
                            With Select.AnnotationsCommands.MoveSelected(Nothing)
                                .Overlay = Overlays.OverlayType.AnnotationsOverlay
                                .Prompt = _
                                    "A watermark has been placed on the image." & vbLf & vbLf & _
                                    "ROTATE and TRANSLATE the image." & vbLf & vbLf & _
                                    "OK to CONTINUE, CANCEL to RESET."
                                .Interactive = True
                                .InteractionLocation = McCommand.InteractionPosition.OutsideBottom
                                .Run(docB)
                            End With
    If there are some other options for the PROMPT, that would be great.

    I think the answer for this user may be to split the ROUTINE into two parts ( A and B ).  This will allow the USER INTERACTION to happen in the gap between A and B rather than during the PAUSE generated by PROMPT.  This will let them continue with a large CONTINUE BUTTON that is in the APPLICATION DIALOG BOX rather than a small OK BUTTON.

    Thanks.

    -- Matt

    *-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-

Sign In or Register to comment.