How can I receive a notification when the Action Button on the Microsoft Band is pressed? - microsoft-band

I can create a Band tile with a text button and receive notifications if that text button is pressed. But I really would like to use the Action hardware Button on my Microsoft Band. How can I receive a notification when the Action Button on the Microsoft Band is pressed?

You cannot. Nothing in the SDKs I've seen lets you do that.

Unfortunately that is not supported by the official SDK.
But some 3rd party apps have managed to use the button by using raw Bluetooth, but you would have to reverse-engineer the protocol used by the Band.

Related

Possible to implement draggable view with Xamarin Forms without using native Andriod/IOS code?

Is it possible to implement a draggable view with Xamarin View? Is there basically an event that I can use that gets triggered when a finger is pressed on the screen, then moved and then released without having to use native Android/iOS code? I don't mean a swipe event, I know this exists. I am looking for a event so I can let the user be able to drag a rectangle across the screen for example.
Looked for it on the internet, but can only seem to find just normal Touch, Swipe and Tap events. (Although I found it is possible using native Android/IOS code.

WatchKit Modal Sheet top right "Done" button

This has been asked in 2015 and 2016 but maybe WatchOS 5 brings a change to this:
When presenting dictation input, the user can click 'cancel' as well as 'done'. I would like to use this for a modal sheet in my app as well. Unfortunately I can't find any API on how to create this button. Is this private API?
Here is a screenshot of what I mean (right picture) https://mikebluestein.com/2015/05/02/voice-dictation-with-watchkit-and-xamarin/
Thanks
That's correct, Apple hasn't made a public API for that, and the Done button in the question article's screenshot is unique to Apple's own presentTextInputController(withSuggestions:allowedInputMode:completion:). I'd file a suggestion with your developer account in Bug Reporter → watchOS + SDK → WatchKit.
If you only need a Done button and not a Cancel button as well, what you could do is present a modal and change the top left title text from away from the default "Cancel" to "Done".

Adding custom buttons to send message notification using Microsoft Band SDK

I have been playing with the Microsoft Band SDK and I have figured out that it is possible to create custom tile layouts and buttons along with event click receivers like ACTION_TILE_OPENED, ACTION_TILE_BUTTON_PRESSED, and ACTION_TILE_CLOSED.
However, is it possible to add custom buttons when doing send message notifications? Such that when a message is receive, the user can swipe left and see additional action buttons he/she can tap, and also tie this button to a click handler method? I have been trying to figure this out all day, but no success.
Example:
When a text (SMS) message is receive in the band, you can swipe left to see two buttons: "Dismiss" and "Reply". I was wondering if it is possible to also create this type of notification with buttons.
No, currently there are no means to customize notifications (messages or dialogs) sent to the Band.

Launch watchkit app from long custom notification content area

I'm trying to implement a feature such that users can click on the notification content area (not app icon nor action buttons) to bring the main watchkit app open. The current official way to launch the main watchkit app is to tap the app icon or action buttons in a notification scene. But I feel like the app icon is actually quite small (and hard) to tap and sometimes users are not even aware of this feature.
What I'm trying to do now is to put my notification content into a table row in the notification controller and make this row clickable. This will give user a pretty big area to tap with. Then in the click event handler I'm trying to open the main watchkit app. But I haven't figure out a way to do that (none of the general navigation methods such as presentControllerWithName works from notification controller).
Any suggestions?

Flex: Simulate key press

I'm creating a virtual keyboard for a touchscreen Flex app and i'm trying to simulate a key press by dispatching a KeyboardEvent. I've written a handler function to listen for the event and act accordingly. So far so good... but it's starting to get complicated as i have to manage the focused textInputs (easy), the cursor position in those fields (not to so easy), etc.
Now, if only there was a way to actually dispatch a KeyboardEvent that Flex would actually interpret as a genuine key press all those issues would be gone... Is that possible?
The TextInput does not use KeyboardEvent/TextEvent for text input, it uses internal Flash TextField objects that interact with the Flash Player / Keyboard.
The KeyboardEvent are used to enable notification of the Keyboard Event that occured.
To simulate a keyboard, you will need to create a class that upon recieving a KeyboardEvent will modify the text property of a TextInput and the cursor position accordingly.
Alex Harui has written a similar post about this FlexCoders Post

Resources