Accessing WinRT From Desktop apps (Part 1)

Thursday, September 13, 2012

The Windows Runtime (WinRT) is the underlying runtime for Windows 8 Store Apps (“Metro”), but some of it can be actually used outside the Metro environment, in regular desktop apps, such as pure Win32, MFC, etc.There are several ways to go about it; most of the time we’ll use the Windows Runtime Library (WRL) to help out with some of the low level details. Or, for a true high level abstraction, we can use the C++/CX extensions to the C++ language (making our code non-standard). But, just for kicks, let’s see how we can access WinRT types with no...

Can Windows 8 Apps Share Memory?

Tuesday, August 21, 2012

Windows 8 Applications (formerly Metro) run inside a sandbox, making communicating with other application difficult at best. There is no easy way to do it, and for good reason, too. When one app is running, all other may be suspended, so what’s the point of communicating anyway? Furthermore, there is no guarantee that the other app even exists on the machine.Still, suppose we wanted to share some information (I’m not talking about the standard share contract) via (say) shared memory. Can we achieve that?Flipping to the documentation of the CreateFileMapping Win32 API shows that unfortunately this is only available...

Should I switch to Windows 8?

Sunday, June 10, 2012

That’s the question I was asking myself in the past few days. Ever since Windows XP, I’ve installed the latest Microsoft OS in beta form on my main work machine. I’ve installed Windows XP Beta, Windows Vista Beta and Windows 7 Beta. With Windows 8 approaching quickly, passing the Beta milestone (RC is out), I have not installed it yet on my work machine. I did install it on a virtual machine, though. Why am I hesitating? For the first time in more than 10 years – I feel uneasy with the next Microsoft client OS. It started...