10 Replies Latest reply on Aug 17, 2012 9:57 AM by andreas

    PITagSearch WebPart

    jmbujold

      One of the biggest expectation from my endusers is to have the ability to populate PI webparts (RtTrend, RtValues, ...) with multiple PI points based on an adhoc "search and multiple select" without going into web page edit mode.

       

      Ideally, here is a mockup of how I would see this based on the PIWebPart "Modify Shared Web Part" dialogs.

       

      PI-TagSearch-WebPart-Scaled-Down.jpg

       

      Now, its all a question of how to build this or if OSIsoft has plans for something similar...

       

      JM

        • Re: PITagSearch WebPart

          As far as our plans to implement such as web part on our end, I'll let the PI WebParts team answer . In the mean time, you can accomplish similar results by using a combination of:

          • The "Find and Display PI Points with MOSS Search" Accelerator, available under the "OSIsoft - Microsoft Accelerators" branch of the vCampus Library
          • A filter web part that displays the tags and "feeds" other web parts such as RtTrend, RtValues, etc.

          Hope this helps!

            • Re: PITagSearch WebPart
              jmbujold

              Thanks.  I'll look into this.

               

              JM

                • Re: PITagSearch WebPart
                  formerpigeek

                  We are currently in the development cycle for PI WebParts 3.0 and the planning and early development of key features for PI WebParts 4.0.  A tag search web part is in our list of optional features for PI WebParts 4.0, which is scheduled for 2010.  We appreciate your feedback about your customers’ expectations since this helps us prioritize which features are included in the releases in our roadmap.

                    • Re: PITagSearch WebPart
                      pkaiser

                      Another workaround available today is to use a Microsoft Form web part to pass a tag search specification to the placeholder in a relational dataset assigned to an instance of RtTable. This relational dataset can use the provided search specification (i.e. "sin%") in a PI OLEDB query, and return a list of PI Points whose name match the search specification. With the list of matching PI Points displayed in RtTable, a connection between RtTable and RtTrend will allow the user to select PI Points in RtTable and have them appear as traces in RtTrend. If you clear the "Replace Adhoc Traces" checkbox in RtTrend, then each PI Point selected in RtTable will be added to the traces already shown in RtTrend.

                       

                      Ultimately, we will have a tag search web part as Tamara indicates.

                • Re: PITagSearch WebPart
                  hans-otto

                  I have done something nice using the Content Editor WebPart and JavaScript. Here is some HTML and JavaScript code that can be inserted into a standard Content Editor web part along with the RtTrend part on a page. The button code invokes the Tag Search dialog, and when the user clicks OK the tags are broadcast to the RtTrend as a tag list. Also, RtTrend can be configured to add or replace these ad hoc traces. 

                   

                  To set this example up, put following web parts on a new web part page

                  • RtTrend
                  • RtTimeRange
                  • Content Editor webpart

                  Go to the configuration of the content editor, toggle the "Sourcecode Editor" button and paste in following JScript code:

                   

                  <P align=right><INPUT onclick=_getPITag() type=button value="Tag Search..."></P>
                  <SCRIPT language=Javascript>
                  function _getPITag()
                   {
                   var tags = "";
                   var tagsDoc = new ActiveXObject("MSXML2.DOMDocument");
                    try
                     {
                     var rslts =
                     window.showModalDialog ("/rtwebpartresources/tagsearch.aspx?lcid=1033&langid=1033", "", "dialogHeight:620px;dialogWidth:390px");
                      if (rslts != null)
                       {
                       tagsDoc.loadXML(rslts);
                       var trcs = tagsDoc.firstChild.nextSibling.selectNodes("TagSearchSelectedItem");
                       for (i=0; i<trcs.length; i++)
                        {
                        tags += trcs.item(i).firstChild.text + ";";
                        }
                       }
                      tags.length--;
                      WPSC.RaiseEvent("webPartDataConfig","AdhocTags",tags);
                     }
                   catch (e)
                    {
                    }
                   }
                  -->
                  </SCRIPT>

                  Finally your page can look like this:

                   

                   Untitled.jpg

                   

                  Just for your information: This code relies on undocumented, unsupported XML data returned from the tag search web service. The call to broadcast the tag list is also undocumented and unsupported. This code assumes the US locale and English language. Future versions of RtWebParts may break this code.