Products & Services Solutions Academia Support User Community Company

Learn more about OPC Toolbox   

disconnect - Disconnect opcda object from server

Syntax

disconnect(DAObj)

Description

disconnect(DAObj) disconnects the opcda object DAObj from the server. DAObj can be an array of objects.

If the disconnection from the server was successful, the function sets the DAObj property Status value to 'disconnected'. You can reconnect DAObj to the server with the connect function.

If DAObj is an array of objects and the function cannot disconnect some of the objects from the server, it disconnects the remaining objects in the array and issues a warning. If the function can disconnect none of the objects from their server, it generates an error.

Examples

Create a Data Access client and connect to the server:

da = opcda('localhost', 'Matrikon.OPC.Simulation');
connect(da);
get(da, 'Status')

Disconnect from the server:

disconnect(da);
get(da, 'Status')

See Also

connect | propinfo

  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS