RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TADOConnection.Commands Property

Lists all active commands for the connection component.

Pascal
property Commands [Index: Integer]: TADOCommand;
C++
__property TADOCommand Commands[int Index];

Use Commands to access active command components associated with a connection component. An active command component is one that is currently open. 

Commands connected through an ADO connection object can be accessed in sequence through the Commands property in a loop based on CommandCount. For example, to execute all of the TADOCommand components connected through the TADOConnection component ADOConnection1:

var
  i: Integer;
begin
for i := 0 to (ADOConnection1.CommandCount – 1) do
    ADOConnection1.Commands[i].Execute;
end;

 

for (int i = 0; i < ADOConnection1->CommandCount; i++)
  ADOConnection1->Commands[i]->Execute();

 

DataSetCount 

DataSets 

CommandCount 

Accessing the Connections Datasets

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!