This happens because there is no QueryAdapters property...
To access the main query adapter's command, use this:
XDocument.QueryAdapter.Command
To access a secondary adapter's command, use this:
XDocument.DataObjects["Detail"].QueryAdapter.Command
Hope this helps. Also using F1 while editing the code is very helpful, just hit F1 on XDocument to get more info about it.
David Airapetyan / Software Services ArchitectQdabra® Software / Streamline data gathering to turn process into knowledge