flushdata
Remove all logged data records associated with dagroup
object
Syntax
flushdata(GObj)
Description
flushdata(GObj)
removes all records
associated with the dagroup
object GObj
from
the toolbox engine, and sets RecordsAvailable
to
0
for that object.
GObj
can be a scalar dagroup
object, or a
vector of dagroup
objects.
Examples
Create a connected client and configure a group with two items:
da = opcda('localhost','Matrikon.OPC.Simulation'); connect(da); grp = addgroup(da,'ClearEventLogEx'); itm1 = additem(grp,'Random.Real8');
Acquire 10 records using a logging task:
grp.UpdateRate = 0.5; grp.RecordsToAcquire = 10; start(grp); wait(grp);
Examine the records available:
recordCount1 = grp.RecordsAvailable
Flush all data from the client:
flushdata(grp) recordCount2 = grp.RecordsAvailable
Version History
Introduced before R2006a