7 Replies Latest reply on Oct 30, 2009 2:48 AM by spilon

    Connecting Web Parts to a Form

    s.grainger
      I'm not sure if this is possible but I thought that I would ask before spending a lot of time on it.  Basically I want to have a dropdown in a form and depending on what the user picks I want the other WebParts on the page (values, trends, etc) to update with the corresponding tags.  I don't want the dropdown to contain specific tags.  I want it to contain something like an equipment name and from that equipment name the tags in the other WebParts on the page are updated. I have been playing around with text boxes and connections and I am able to get the WebParts to update if I type the complete tag name into the text box and then use the connections to pass the tag name to the other WebParts.  Doing some preliminary brainstorming I figured that I could have the dropdown and compile the tags in hidden labels and connect those to the WebParts but I'm not sure if thats the best way to do it.  I also thought of using a mapping file like a CSV so if option1 was picked in the dropdown it would go and find the tags in the CSV based on what option was chosen.  I'm just throwing out ideas here that I think could work.  If anyone else has done this already any feedback would be very much appreciated!
        • Re: Connecting Web Parts to a Form
          andreas

          Hi,

           

          have you had a closer look to the RtTreeView web part?

           

          This could be used to pass a list of tags to a trend by clicking on a module. You can use a hierarchical visualization of your equipment and the user can select the appropriate equipment (= module). The RtTreeView can also be used to navigate to different pages and/or select a graphic for an RtGraphic web part. By this you could maintain the list of tags as aliases in the MDB on the PI Server, so no need to maintain CSV's or other lists on a separate server.

           

          To follow up on you initial idea, the form web part in share point shows a simple text box, but in fact is just showing Java Script - so you can extend this web part to contain drop down box etc.

           

          regards,

            • Re: Connecting Web Parts to a Form
              andreas

              In case i could not convince you of the RtTreeView :

               

              Here is some sample code for the Form Web Part:

              <SELECT NAME="Equipment1" onchange="java script:_SFSUBMIT_">
              <OPTION VALUE="CDT158">Pump
              <OPTION VALUE="SINUSOID">Tank
              <OPTION VALUE="CDT158;SINUSOID">All
              </SELECT>
              <BR>
              <INPUT TYPE=radio NAME="Equipment2" onclick="java script:_SFSUBMIT_" VALUE="CDT158">Pump<BR>
              <INPUT TYPE=radio NAME="Equipment2" onclick="java script:_SFSUBMIT_" VALUE="SINUSOID">Tank<BR>
              <INPUT TYPE=radio NAME="Equipment2" onclick="java script:_SFSUBMIT_" VALUE="CDT158;SINUSOID">All<BR>

              Note that i have put a space between java and script to avoid that it gets filtered by the forum.

               

              Regards,

                • Re: Connecting Web Parts to a Form
                  s.grainger

                  Thanks for the tips.  We aren't using module database currently because there is simply no one to maintain it.  We have about a million points in our PI system so it would take a bit of work to set it up.  Will module database eventually be phased out by PI AF? 

                   

                  Thanks for the javascript.  I will try it and let you know if I run into any problems.

                    • Re: Connecting Web Parts to a Form
                      andreas

                      Hi,

                       

                      from the engineering plan: Version: 3.0 / Projected Release: 4Q2009 / Feature Description: AF support within existing web parts. Support for 64-bit operating systems.

                       

                      From the same source, this time for the PI Server: Version: 3.5.385.xx (PI Server EAM) / Feature Description: Makes all MDB applications AF aware

                       

                      So yes, we are working on native AF support in our clients.

                       

                      Regards,

                      • Re: Connecting Web Parts to a Form

                        s.puff

                        Will module database eventually be phased out by PI AF?

                         

                        Absolutely: even as of today, we recommend people to start using AF rather PI Module Database (there are however a few exceptions where using PI ModuleDB is inevitable, such as with PI Advanced Computing Engine - PI ACE).

                         

                        Also, the next version of the PI Server (version 3.5.385.x, labeled EAM for Enterprise Asset Management) represents a major milestone in that area: it will unify both asset hierarchies (ModuleDB and AF) and make AF the system of record, while still allowing legacy ModuleDB applications to access the asset data. This will be made possible via a new subsystem: PI Asset Subsystem. As per the Engineering Plan, this is targeted H1-2010.

                      • Re: Connecting Web Parts to a Form
                        s.grainger

                        We decided to go with rtTreeView instead of the From Web Part.  Now I have a few more questions.

                         

                        1. In a module I have 20 aliases but in my rtTrend I only want to show 4 of those 20 aliases.  In my connections in rtTrend i'm using "RtTreeView:Alias Tag List" so its grabbing all 20 aliases.  What is the best way to go about only trending the 4 aliases?

                         

                        2. Can I connect rtTreeView to rtActiveView to put tags into a process graphic?  I would like to specify that the Temperature Alias gets input to the Temperature Value box in rtActiveView.

                          • Re: Connecting Web Parts to a Form

                            You can use the "PI Aliases Template Node" setting of the RtTreeView web part configuration, to filter on only 4 of the 20 aliases. The module specified in that setting (a dummy one, usually) would contain only the 4 desired aliases.

                             

                            Then regarding the connection of RtTreeView to RtActiveView, yes it is possible to connect those to pass the path of the selected module to RtActiveView. Then if the PDI file that is displayed by RtActiveView is a Module-Relative Display

                             

                            As far as using/configuring the web parts (as opposed to developing web parts), I invite you to take a look at the RtWebParts User and Administration online course and contact Tech Support if you need further assistance. The Module-Relative Display feature of PI ProcessBook is further discussed in the PI ProcessBook, PI DataLink and RtWebParts online course.