Hooks in Windows 8 apps - windows-8

I am trying to extract UI data from a Windows Store App. So far I have tried SetWinEventHook but have had little success. I have also tried to install a setWindowsHookEx hook into a windows store app, but it returns a 0.
MSDN has very little documentation available on this topic. What is the best way of hooking a metro app? Also if there is any other way to extract UI data?
Links:
http://community.nvda-project.org/ticket/1801
http://forum.nektra.com/forum/viewtopic.php?f=9&t=6228
Have not been able to figure out how the above links got this done.

Why are you trying to do this with a window hook? Most store apps don't use standard windows controls (they don't have windows in the normal sense).
I would try UI automation to enumerate the visible controls and interact with them, that might work.

Related

af:inputfile drag and drop not supported in IE11

For one of our clients we are building a web application with oracle adf.
One of the requested features of this application is having a drag-and-drop file upload.
Fortunately the af:inputfile component supports this feature out of the box.
Unfortunately that feature is not supported in Internet Explorer 11, which we absolutely have to support.
Now I have been trying to get it to work using the dropzone.js library and the drag and drop functionality seems to be working. but I haven't been able to get the POST request to the ADF side of things quite right.
Even if I did it would be a lot of custom code that would have to be maintained, if it's the only way to make it work that is fine but if there is a more elegant solution to this I would like to know.
What you can do is to use ADF JavaScript APIs, more specifically AdfFileUploadManager(https://docs.oracle.com/middleware/1213/adf/api-reference-javascript-faces/oracle/adf/view/js/util/AdfFileUploadManager.html)
You need to instantiate it by giving it the ADF Component reference, which that can be an af:inputFile with display="none"
Then you can utilise your DropZone or any other functionality and use addFileToQueue to send this information to server side and convert it to UploadedFile.

IBM Worklight - Can we create a custom dialog for Direct Update?

How can we use custom dialog box for direct update in worklight 6.0?
Is there any option in wlclient.js? I don't know where it should be customized in the application.
Worklight 6.0 does not provide developers the ability to create a "custom dialog box" for Direct Update.
You can submit a feature request: http://www.ibm.com/developerworks/mobile/worklight/connect.html
So Idan already answered, but I did a lot of digging prior to his answer and I thought I'd share my findings just because I spent so much time on it.
Sifting through the code, through all the checks it does to see if a Direct Update is needed, it calls an update method for the app. It utilizes a Cordova plugin called 'WebResourcesDownloader'. In turn it calls the necessary native components and that's how you get a native handler for the downloader (it is in the worklight-android.jar for Android). So, long story short, you can't customize the box itself because its rendered via the plugin/native components and you can't modify the plugin directly (not that I know of at least).
However, you can at least update all the notification messages surrounding the update in the messages.js within the wlclient folders. =)

"Guided Access" equivalent

I have to develop a windows store app which will be usable on public devices, that means users aren't supposed to be able to quit my application.
On iOS devices, an option called "Guided Access" allows to do this easily, buttons are disabled and you can specify an area where user can interact.
After some researches, I haven't found a way to do that, it seems that Microsoft has not implemented this option in Windows 8, so I'm looking for a way to do this with some code, directly in my app but I have no idea on how to do that precisely. Please, can you tell me if it's possible and, if it is, can you give me a point where I can start ?
Thanks.
I´m not sure whether or not this made it into the newly released preview of the Windows 8.1 Update, but check for "Assigned Access" it was rumored to be a new feature especially for Windows store apps
Edit: See the offical 8.1 product guide here, it only mentions it two times but maybe it is worth installing the preview.

How to add dynamic text to live tile in windows 8 with javascript

Well, the topic says it all. I'm dabbling with windows 8 app development using html/css/javascript and I'm having a hard time finding information on how to dynamically manipulate the live tiles.
There is a lot of information out there on how to create multiple tile xml files and launch them after each other but if anyone had a good resource, or even better, a first-hand explanation, on how to create these tiles programatically to, say, make a countdown tile, it would be greatly appreciated.
There's no way to programmatically update the text/image on a live tile directly in real time.
The only APIs available are those in the Windows.UI.Notifications namespace, such as are shown in the Sending a tile update Quickstart.
You can use the notification queue, as shown here, to provide multiple updates that will automatically cycle, or you can use an external service, such as Windows Azure Mobile Services to send tile updates. Using push notifications from an external service will probably get you closest to the behavior you're looking for, since it will not rely on the app being active in order to update the tile. Be aware, however, that the app will need to run at least once in order to create the channel URI that's needed for the external service to update the tile.
For more info on Windows Store app development, register for Generation App.

Obtain control names in Windows application

Haven't found this in my search on Stackoverflow - I know I've seen a tool like it before, for obtaining control names or IDs in Windows apps which can then be used for reference in automated testing, in tools like AutoIt. Can anyone suggest one?
I've tried the OLE/COM Object Viewer and while it has control lists, there's no interactive method with it. Like the web developer toolkit in Firefox where you can click a control and get all the information about it, I'm after a similar app for Windows testing.
It's called Spy++.
Found the tool I wanted, either NUnitForms - which means you can use the NUnit Framework to access windows forms, and includes a Recorder tool for identifying the controls, as well as Managed Spy for giving the individual component names as well as every bit of other info - font, color, size. Very nice.
NUnitForms : http://nunitforms.sourceforge.net/
ManagedSpy: http://msdn.microsoft.com/en-us/magazine/cc163617.aspx