Reputation: 27
I am designing some application using Universal app from visual studio, and i would like some code to execute when the program is running on phone or tablet, the phone part is not a problem since i can use '#if WINDOWS_PHONE_APP' but how can I know if the application is on a tablet?
Upvotes: 0
Views: 68
Reputation: 12019
If you want to detect a keyboard, use the KeyboardCapabilities object. Note that starting with Windows 10, phone can also have wireless keyboards attached.
Upvotes: 1