we have customers who love the vt_trend and the features that it provides. The ability to configure a trend group and bring it up on demand within a timeframe, etc. are all great features.
I spent a couple of hours taking the buttons apart in the Panel Topology for the trend, and I just can't seem to figure out how to get it to open in the mainModule, not as a floating popup.
Our customer wants to always open the alarm panel on one monitor, the trend on another monitor and then navigate in a 3rd monitor. The trend and alarms screens won't change very often.
Before I spend another day messing with this, has anyone built a button that opens the standard VtTrend in the mainModule frame rather than a popup.
Todd Malone
HMI CoC USA
vt_trend in the mainModule
- Gertjan van Schijndel
- Posts:634
- Joined: Mon Aug 02, 2010 10:37 am
Re: vt_trend in the mainModule
You can easily do this by adding a optional parameter to the 'openTrend' function like this:
And change the previously fixed module name (at the end of the function) with the new parameter like this:
With these changes you can call the 'openTrend' function to open the trend in your module, like this:
To prevent from making these changes also in future versions, you could try if ETM is willing to incorporate these changes in their product.
Code: Select all
void openTrend(string trendName, int trendType, string moduleName = "Trend_" + myModuleName())Code: Select all
mergeToString(transferstring, transfer);
dpSet("_VarTrendOpen.UiNumber", myUiNumber(),
"_VarTrendOpen.PanelName", moduleName + ": " + trendName,
"_VarTrendOpen.TrendData", transferstring);
}
else
{
DP = "";
}
ModuleOnWithPanel(moduleName,
0, 0, 0, 0, 1, 1, "",
"vision/trend/VT_trend.pnl",
trendName,
makeDynString("$VARTRENDDP:" + DP));
}Code: Select all
openTrend("VarTrend_0001", -1, "myMainModule");