locked
Unable to use FindAllAsync with non-canonical name

    Question

  • These two forms are supposed to be identical right?

    string selectorA = "System.Devices.ContainerID:={myGUID}";
    string selectorB = "{8C7ED206-3F8A-4827-B3AB-AE9E1FAEFC6C} 2:={myGUID}";
    var devices = await Windows.Devices.Enumeration.Pnp.PnpObject.FindAllAsync(Windows.Devices.Enumeration.Pnp.PnpObjectType.Device, props, selectorA);

    however selectorA works while selectorB raises an exception - "WinRT - Full text search not available"?  Any ideas?  I tried various combinations of quotes but nothing works with B.

    • Edited by Payne Cash Monday, July 23, 2012 5:09 PM
    Monday, July 23, 2012 5:08 PM

Answers

  • Payne,

    You can only filter on properties with canonical names.  This is a limitation of the AQS parser.  It needs to know the type of the property to correctly parse the value portion and the type is specified in the canonical name declaration.

    Best Wishes - Eric

    Tuesday, July 24, 2012 5:48 AM
    Moderator

All replies

  • Payne,

    You can only filter on properties with canonical names.  This is a limitation of the AQS parser.  It needs to know the type of the property to correctly parse the value portion and the type is specified in the canonical name declaration.

    Best Wishes - Eric

    Tuesday, July 24, 2012 5:48 AM
    Moderator
  • Hi Eric, Thanks as usual for your insight & quick reply.  Understood.
    Tuesday, July 24, 2012 4:18 PM
  • Payne,

    You are welcome.

    Best Wishes - Eric

    Tuesday, July 24, 2012 4:32 PM
    Moderator