9 Replies Latest reply on Jun 2, 2016 2:24 AM by dcho

    Trend - style

    BrentAWebster

      Has anyone ever tried to remove the buttons and time items off of a trend? 

       

       

      In preferences there is no none just the style.  same in the trend properties.

       

      The trends are fixed always 10 min with y scale range differences. In a small version the buttons disappear but not the minutes.

       

      Need to be able to remove the refresh, left right, zoom in out and time (minutes) in this case.

        • Re: Trend - style
          John Messinger

          I don't believe that these are exposed through the automation interface, so VBA customisation of these elements isn't possible. Nor have I seen any properties within the procbook.ini file that seem to point to these specific visual elements.

          What's your specific requirement for making these elements not visible?

            • Re: Trend - style
              BrentAWebster

              I think that a clean visual is the biggest reason but also the removal of buttons so not trying to click on trend as it will be disabled to not enlarge or change.  Touchpoint will be added to open a toss away add hoc

              Trend that can be manipulated.  The original is a dashboard and when there are 4 + trends it adds to busy look of screen

               

              Thanks

                • Re: Trend - style
                  John Messinger

                  I hear what you're saying about having a clean visual, but I think you may be out of luck with removing these particular visual elements.

                   

                  You can programmatically prevent trends from being modified by putting a little bit of code in the Click(), BeforeDoubleClick() and BeforeRightClick() events handlers for a trend. We needed to do this in a recent project. In each of these event handlers, set the Selected property of the trend symbol to False. In the BeforeDoubleClick() and BeforeRightClick() event handlers, also set the value of the bCancelDefault parameter to True. If you want users to be able to double click a trend to enlarge it to full size on the display, don't use the BeforeDoubleClick() handler. There are other events on the trend symbol that you could probably handle to effectively disable functionality such as Zoom, or TimeRangeChange, so that clicking on the relevant buttons is effectively disabled, but I haven't really explored those options myself as yet.

                   

                  Main downside to this approach is that you need to repeat this for each Trend symbol on the display, but it does allow you to implement some modification limitations to a display where required. Other downside is that none of this will work if you intend to use your PDI displays in PI Coresight.

              • Re: Trend - style
                mnorton

                Dumb workaround, but you can always cover parts up with boxes matching the background color:

                You can change the colors of the trend to make things look nicer as well, if you want.

                • Re: Trend - style
                  dcho

                  We do have an enhancement request for this exact feature at the link below, but there is no targeted date for a fix.

                   

                  22412OSI8 - Hiding buttons and disallowing pop-ups in ProcessBook Trend

                   

                  As for a workaround, I have a feeling that going with what Michael Norton proposed might be your best bet. I do not see another easy way to do this, and other methods will most likely require the use of VBA.

                    • Re: Trend - style
                      BrentAWebster

                      If you know of a vba solution I am not opposed to that in a display open event.

                       

                      If not thanks for the help.

                       

                      Brent

                        • Re: Trend - style
                          dcho

                          I looked through our database to see if there was any luck with editing this via VBA, but it does not seem like there is any method to do this as this seems to be hardcoded, and as John Messinger mentioned, these trends are not exposed in VBA as well.

                           

                          If you make the trend small enough, it will automatically have the buttons disappear because of real estate issues, but this would require some guess-and-check on your end with the sizing.

                           

                          Ex.