Dec 8, 2009 at 2:35 PM

I noticed that any call to collection will result in "Invalid argument '...' to fn:collection".

Is this function still not implemented or am I missing something?

Dec 9, 2009 at 4:56 AM
Edited Dec 9, 2009 at 4:57 AM

For using fn:collection() is necessary to handle event XQueryCommand.OnResolveCollection.
For example:

command.OnResolveCollection += new ResolveCollectionEvent(command_OnResolveCollection);

void command_OnResolveCollection(object sender, ResolveCollectionArgs args)
    if (args.CollectionName != String.Empty)
      args.Collection = CreateCollection((XQueryCommand)sender, args.CollectionName);