Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

Setting the AutomationProperties.AutomationId on Windows Universal apps

$
0
0

For iOS and Android it is possible to use the following to set the AccessibilityIdentifier using code like this:

Forms.ViewInitialized += (object sender, ViewInitializedEventArgs e) => {
    // http://developer.xamarin.com/recipes/testcloud/set-accessibilityidentifier-ios/
    if (null != e.View.StyleId) {
        e.NativeView.AccessibilityIdentifier = e.View.StyleId;
    }
};

The above code is taken from:
http://developer.xamarin.com/guides/cross-platform/xamarin-forms/uitest-and-test-cloud/

For Xamarin.Forms.Platform.WinRT.Tablet.Forms there are not any events defined. Is there another approach to use for Universal Apps in order to set the AutomationProperties.AutomationId of visual elements?


Viewing all articles
Browse latest Browse all 58056

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>