Gets a
Module object that refers to a specific RAPID module.
Namespace:
ABB.Robotics.Controllers.RapidDomain
Assembly:
ABB.Robotics.Controllers (in ABB.Robotics.Controllers.dll) Version: 6.5.129.0
Syntaxpublic Module GetModule(
string moduleName
)
Parameters
- moduleName
- Type: SystemString
Name of the module.
Return Value
Type:
ModuleA
Module object to access the module. If the module does not exist, the return value is
null.
Exceptions
RemarksNOTE:When the returned instance is no longer needed you must call its Dispose method.
Examples This example deletes all modules with a certain name in
each task in the controller.
private void DeleteModules(Controller c,string stModName)
{
Task[] tasks;
Module m;
try
{
tasks = c.Rapid.GetTasks();
Modules modules;
foreach (Task t in tasks)
{
m = t.GetModule(stModName);
m.Delete();
}
}
catch (GeneralException ee)
{
}
catch (System.Exception ee)
{
}
finally
{
}
}
See Also