ModuleSearchRapidSymbol Method |
Namespace:
ABB.Robotics.Controllers.RapidDomain
Assembly:
ABB.Robotics.Controllers (in ABB.Robotics.Controllers.dll) Version: 6.5.129.0
Syntax Exceptions Examples This example retrieves all
RapidData instances in the module that
are used and declared on Module level. The name, datatype and value are added to a listview.
private void GetModuleData(Module m)
{
try
{
RapidSymbolSearchProperties sProp = RapidSymbolSearchProperties.CreateDefault();
sProp.SymbolType = SymbolTypes.Function | SymbolTypes.RapidData;
sProp.IsInUse = true;
sProp.Recursive = false;
sProp.SearchMethod = SymbolSearchMethod.Block;
RapidSymbol[] datas = tT_Rob1.SearchRapidSymbol(sProp,string.Empty,string.Empty);
RapidData rd;
foreach (RapidSymbol rs in datas)
{
rd = rs as RapidData;
if (rd != null)
{
ListViewItem li = new ListViewItem(rd.Name);
li.SubItems.Add(rd.DataType);
IRapidData iVal = rd.Value;
li.SubItems.Add(iVal.ToString());
listView1.Items.Add(li);
}
}
}
catch (System.Exception ee)
{
}
}
See Also