I'm trying to follow this StackOverflow article, referring to this similar article on StackOverflow, and this from the UWP Windows Dev Center.
In my manifest XML, the <Package>
tag was updated to include xmlns:rescap="http://schemas.microsoft.com/appx/manifest/foundation/windows10/restrictedcapabilities"
and also IgnorableNamespaces="uap mp wincap rescap"
.
My <Capabilities>
section looks like this:
<Capabilities>
<Capability Name="internetClient" />
<rescap:Capability Name="inputForegroundObservation" />
</Capabilities>
And <rescap:Capability
is underlined with error:
"The element 'Capabilities'... has invalid child element...in...namespace.../windows10/restrictedcapabilities..."
(I snipped away much of the very long error message)
Any advice on how I can get the inputForegroundObservation Capability recognized? VS Community 2015 sp3, Microsoft.NETCore.UniversalWindowsPlatform package installed.
Cheers, Adam
Answer:
<package>
tag, do not includewincap
orrescap
inIgnorableNameSpaces
.rescap:Capability Name=
will continue to be underlined in the package XML editor, but this does not mean you will have any build warnings or errors.rescap
"must" be included inIgnorableNameSpaces
- this was clearly throwing me off, and may well confuse others, also.Hope this helps someone.
Cheers,