1 Reply Latest reply on May 21, 2013 3:26 AM by hanyong

    settagname to data set

    scm0094

      I know this is probably extremely easy...I'm just having trouble figuring out the correct syntax.  Could someone post a snippet of  VB code that shows how to set a tag name on a ProcessBook display symbol to a data set.  I have a trend on my ProcessBook display that users can click buttons to change that values in the trend.  This works great when changing to other PI tags, but I'm having trouble getting the trends to change to data set values.

        • Re: settagname to data set
          hanyong

          Hi Shawn,

           

          Not sure what dataset you are using here. But if you are talking about PI Calculation and ODBC dataset then the format for adding it to a dynamic symbol like trend is the DatasetName.ColumnName. This post from a previous discussion has an example of adding PI Calculation Dataset and adding it to a trend through ProcessBook VBA. The last 2 statements is where we add the dataset to the trend.

           

          For ODBC, it should be similar except that the Column Name portion is the column name returned from the query.