Windows 8 Programming Summary

Leave a comment

As you know, Microsoft release Windows 8 recently. As MSDN Subscriber, you can download the windows 8 developer preview  and install the virtual system[see my previous post about installation of windows 8 on virtualbox].

Basically, windows 8 is really a kind of COM “reimagined” [cited from Matt,Merry’s speech], and Microsoft try to build cross-language[sure ,Application development language in User application space] based on Windows Platform, instead of something tried with MSIL  in virtual system.

For Application developer, the world seems turn back to 10 year ago, when we still keep love with COM[Still remember IUnknown, Dispatcher, the amazing API QueryInterface, and Thread Apartment, etc… Win32 Dll…].

Actually not yet, refer to description. Now windows application consists of :

  • Metro Application – I’d like to call it Metro Style Applicaiton [I like Raf’s idiom, just a kind of new working style for windows application. The kernel of application still is dispatched to IPC, etc]
  • Classic Desktop Application – tradional windows application style

The core of User space application has been totally changed into COM with metadata. Take Metro application as example, wmahost as service host to invoke DCOM object and generate application with its own resource based on platform API.

As metadata built on platform[not depends on virtual system], the runtime performance has the possibilities to enhance a lot, esp. for language out-of-virtual system. We say, c++ is back, King is back.[I questioned that C++ Extension is a kind of something like Objective-c, similiar].

Please check up with Raf’s description, great*N post, if you want to know the story behind, not satisfy to just work it out.

And if you have time, please check up with Matt’s speech on windows 8 build, great speech.

Thing come back, What do you need to do here for real development preparation? [Perhaps, just take a note for what I have done here.]

  1. Metro application Guide –
  2. However, if you try to do something with IPackageDebugSettings [win32 API] to enable debug or something different from standard metadata definition of platform COM, you have to install Visual Studio 11 Ultimate developer preview to support both Metro and Desktop application.

By the way, VS2011 Ultimate depends on some components, which are included inside VS2010.[strange ^_^, that’s why it’s pre-developer version]. So take care of that, in case you meet with installation error.

The simplest solution is to install VS2011 side with VS2010, However, the final solution is to check up with installation error, and install missing component separately.

OK, ready, go to Metro application:

  1. – Metro application sample, for Application developer, it’s sufficient.
  2. – Windows 8 team blog
  3. My favoriate – Metro COM Programming interface, amazing!!! you can do a lot of things, Just as Matt has bee done in amazing and awesome details, I like it, that’s the real world looks like.

Though just a kind of links and video on channel 9, it’s already a great changes.

So basically for Metro/Desktop application in windows 8 , if you just use the standard platform/C# API, it’s cross-language. based on metaCOM, you can do things you like.

However, for me, the powerful application in windows 8 application, will look like what Raf has done for DebugEnabler[]. Mix-c++ language programming [Guy, just c++, why mixed?], to bind Windows Platform COM interfaces, STL, WRL together.

And as Charle posted in GoNative9++ facebook, COM interop die! The only thing here is C++ [precisely, C++ Extension, and Portable], Just check up with Herb’s speech in Windows 8 Build conference.

Now C++ world become Clean, Safe, and Fluent. Hmmm, as developer, I don’t want to be lazy, and c++ is a way to keep me.


Windows 8 developer preview installation

Leave a comment

As you know, in windows 8 build conference [this 13- 16], Microsoft already unveiled Windows 8 developer version for us.

As I’m developer, so choose Windows Developer Preview with developer tools English, 64-bit (x64), about 5GB size.

  • Virtual system preparation:

Here, I introduce sun’s virtualbox as host, with version 4.1.2.

Let’s rock…

1, Create new virtual system

step 1 - Create new virtual system

step 2 - choose Windows 7 (64bit)

Step 3 - Create new virtual disk

Step 4 - Select Virtual Disk Type

Step 6 - Dynamic Disk Type

Step 7 – Create Virtual Disk with Dynamic Max Size


OK, then we have to configure boot ISO and Visualization option [As 64 bit virtual system is required for Windows 8 64bit iso booting.]

And you have to enable your BIOS with Visualization option, if your computer couldn’t support visualization, I’m really sorry for you….

Step 8 - System Configuration

Step 8 - Mount your ISO disk

Step 9 - Select your iso

Step 10 - Rock Guys

2, Logging into your windows 8 system, change your screen resolution to larger than 1024. Then you can develop with your Visual studio 2011, with Grid/New application.

Screen shot for Windows 8

Update your screen resolution

Cheer up with Visual studio 2011

Win8 New UI Philosophy

Leave a comment

Is it still windows, which we are familiar with? Change is the only constant thing in the varying world.

Impossible is nothing, Yeah, Microsoft learn a lot from Apple, not just learn, but also a kind of re-creation. Wooo… That’s why I keep learning the MacOSX, the new world.

Let’s rock out of bottle.


Leave a comment

1,今天浏览CSDN看到如下一个思考题 –  简单的N球问题



产生后果:C盘下产生多个uuid的文件夹,试图用rmdir /S xxx删除时出错提示“拒绝访问”



因此直接使用“管理员权限”启动cmd,使用windows的cmd命令:net user administrator /active:yes