Wednesday, May 27, 2009

Keyboard shortcuts for Windows Virtual PC

Friend of mine (hi Henk ;)) was just complaining about the fact that new Virtual PC in Windows 7 doesn’t support keyboard shortcuts anymore (like Alt + Del etc).

I tried it and they works – Microsoft just changed them little bit ;)

To be honest, before running my VM I already had in mind that maybe Microsoft decided to consolidate controls and use same shortcuts in Windows Virtual PC than in Hyper-V… And surprisingly I was right.

So if you want to know keyboard mappings, check out Virtual PC Guy’s blog post – it’s about Hyper-V, however you can use same shortcuts in Windows Virtual PC.

Monday, May 25, 2009

XP Mode for other operating systems

Recently I blogged about internals of XP mode – how it works and I also mentioned that it is NOT only for Windows XP, however also Windows Vista and Windows 7 are supported.

For me personally, this mode is extremely interesting. For example I can try all new applications in my virtual pc first (however use it as RemoteApp from my regular desktop) and when I’ll like them, I can install them to my regular desktop… And if I won’t? Undo changes to VHD ;)

Another reason can be that sometimes you need access to applications that are not available for Windows 7 – I don’t use such legacy applications, but I am scripting in Powershell – and in Windows 7, you have Posh v2 ;) So for testing I can install multiple operating systems and just validate automatically whether my scripts works or not.

So what to do if you want to “publish” applications from Windows 7?


1.) Install Windows 7 to virtual PC

2.) Install Integration components

3.) Create new registry key in location HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TsAppAllowList\Applications\NameOfYourApplication

4.) Create registry entry with name Path (string). Value is location of your application.


Well, that’s it… I tried it and it works for me. All you need to do know is run following from Run (or cmd.exe\powershell.exe, create shortcut, it’s completely up to you):

vmsal.exe "Windows 7" "||IE" "IE"

As you can see below, I run one Internet Explorer from my own OS (glass) and another from virtualized Windows 7:


Running Elevator under normal user

As you maybe remember, some time ago I created small utility (proof of concept) called Elevator that allows you to

  • elevate program seamlessly (without UAC prompt) using context menu
  • create shortcuts that will run programs elevated automatically

Even though it was POC, I received tons of comments and feedback. There is however one question that keeps repeating – Why it doesn’t work under regular user account?

Well, answer is simple and very annoying – Elevator is using scheduled task to run programs elevated. In order to use elevator, you must have permissions to run scheduled task.

As you can see below, there is no Permissions tab in Windows Vista or Windows 7:


I have NO idea why they removed this. If you want to help Elevator, please vote for this bug report:

Friday, May 15, 2009

New perfect movie is coming in 2010

Hehe, really funny advertisement from Microsoft :)

Cloud presentation and list of my tools

To attendees of my yesterday presentation, few things I promised…


Presentation itself:


My Ketarin (to those that didn’t bring USB stick after presentation :)):


Hope you had fun yesterday and enjoyed it as much as I did :)

Tuesday, May 12, 2009

“Get” and Powershell

Sometimes you forget some cool features and remember them after months or event years…

This happened to me few times already with powershell.

So I wanted to share a simply trick I run into by accident. GET is optional in Powershell :)

Therefore you don’t need to write Get-WmiObject (in interactive session), you can use WmiObject without verb.

And it applies to your functions also:

PS C:\> function get-dog {Write-Host "Dog returned"}
PS C:\> get-dog
Dog returned
PS C:\> dog
Dog returned
PS C:\>

Monday, May 11, 2009

Cloud computing – compatibility mode :)

Well, as you all know cloud computing should allow you to have webtop – your regular desktop accessible from Internet (the Cloud).

I think idea is nice, however we are not there yet. There are many solutions that tries to achieve that. Some are providing you with “true” desktop experience, like eyeOS, glideOSiCloud or Startforce, some are still working in “compatibility” mode.

You can ask what compatibility mode means – it’s my term for solutions that are synchronization only and one of “nodes” or computers is online desktop. Good examples are tools like Live Mesh, Syncplicity or Dropbox.

Even though webtops like iCloud are getting nicer and more eye-candy, I still think time for webtops hasn’t come yet. It’s nice to try, however I can’t imagine replacing full desktop with webpage. My first concern is performance – even if uploading\downloading files would be only 50% of time on my desktop (which would be major improvement compared to current solutions), I would still feel it’s too slow.

Second related problem is that I want to store my Windows applications stored in cloud – utilities like Total Commander, Notepad++ or Miranda. Even if that would be possible, running and using such applications would be much slower compared to local access.

Therefore I prefer “tweaked” mutant desktops (half-cloud, half-physical).

My cloud is combination of multiple tools:

  • special outlook rules for synchronization of emails (Outlook\Exchange <-> Gmail)
  • LastPass for password management
  • Live Mesh for synchronization of documents, tools, installation sources
  • Ketarin to keep installation sources up to date
  • FlexProfiles to transfer configuration

Currently I want to have a look at Xmarks – utility to automatically synchronize bookmars (as you maybe remember, I complained that Live Mesh cannot handle conflicts properly and this is especially case with Favorites) and play a bit more with FlexProfiles to create seamless application configuration synchronization tool.

Live Mesh problems on Windows 7 – still open :(

Recently I blogged about problems with Live Mesh and Windows 7… I installed Windows 7 RC1 2 weeks ago and I thought it is working finally – however today morning it was broken again :(

I followed my own instructions and uninstalled Live Mesh – and everything works again.

I opened bug at Microsoft Connect – if you experienced same issues, please vote.

Tuesday, May 5, 2009

How XP Mode works

As promised, some details about VMSal – executable that is used to run published applications… I investigated little bit today and here comes first information :)

VMSal is used to run applications that are published from within virtual machines – and functionality called RAIL is used to achieve that – this feature is better known as RemoteApp in Terminal Services.

It is no surprise that Microsoft just re-used already existing functionality – I would be really surprised if they would try to re-invent the wheel (but you never know – just have a look at Live Mesh and SkyDrive, or Live Mesh remote desktop functionality).

Well, it IS based on TS technology :) You can easily discover following registry keys on virtual machines with RAIL installed:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Terminal Server\TsAppAllowList\Applications

Under this key you can find regular settings of TSRemoteApp:


Name of that key is identifier of published application. BTW I was really surprised by ShowInTSWA – which is used to show published application in Terminal Services Web Access :) I want to play a bit with it and see if I can publish these applications to TS 2008 :)

When Windows 7 tries to run these remote applications, it is using (already mentioned) executable called VMSal.exe, that can be found in %WinDir%\System32 folder. This executable accepts 3 arguments:

  • Name of virtual machine
  • ID of application
  • Name of application (?) – not sure where is this one used, however it can be any string

ID of application is prefixed by “||”, so for example “||fa7d9”.

If you have a look at picture above, if I would like to run Internet Explorer, I can just call following executable:

“%WinDir%\System32\vmsal.exe” "Virtual Windows XP" "||IE" "IE"

That will automatically run “IE” as specified in virtual machine Virtual Windows XP.

So if you want to easily transfer your settings, simply backup all .lnk files on your Windows 7 and all RAIL registry keys from your virtual machine and that’s it. You can easily automate creation of these applications – I will maybe even build small script that will automatically give you all published applications based on your Windows XP start menu…


Virtual PC center is missing?

I just wanted to create new VM to test functionality (RAIL) I was talking about in my previous post, when I noticed there is no Virtual PC available in my start menu…

It turned out that you can either manually run %WinDir%\System32\VPWizard.exe or click on Create virtual machine in folder where you store your virtual machines:


Quick shortcut – if you want to open folder with your virtual machines, just open Run dialog (WinKey + R) and type VMWindow

BTW just out of curiosity, check out the VMSal.exe in Windows\System32 folder – this executable is used to run virtual applications from within virtual PC (at least description is Windows Virtual PC Application Launcher). If you try to run it, you get following error message:


Once my XPM is installed, I will try to give you parameters you can use.

XPM (XP Mode) for Windows Vista & Windows 7

At this moment I am downloading XPM and I want to play a little bit with it… However I was curious why XPM, why not UVM (Universal Virtual Mode :))?

As it turned out, XPM is pretty famous name these days, however technology that we are interested in (publishing of applications from within virtual machine) is not called XPM, it is called RAIL – it means Remote Applications Integrated Locally :)

Most definition of XPM describes it as built-in VirtualPC with free Windows XP license – however that is not complete description. Full definition should be that XP Mode is combination of VirtualPC and RDP. VirtualPC is used as backend (to run hidden virtual PC) and RDP is used to present you with parts of that virtual pc (applications).

RAIL is however not available only for Windows XP, however also for Windows Vista. Check out following links:

I will probably build few virtual machine next week and post some screenshots together with instructions how to enable virtual applications on all these operating systems.

Monday, May 4, 2009

Windows 7 and problems with DWM

Sometimes there are some problems with DWM – for example I use GoToMeeting from Citrix for conference calls, however when you are organizer, your desktop will automatically switch to Aero Basic mode – and once you are finished with confcall, it will switch back to full Aero interface.

Many windows however won’t recover. You can see below screenshot of my desktop:


As you can see, only Skype window is restored, rest of windows are all black. Also notice how taskbar looks like – shining start button, however that’s it :)

It’s very easy to recover once you know that DWN is responsible. Just kill DWM.exe process, it will automatically re-launch and all windows are recovered:


I already saw this few times and it can be quite handy to know what’s wrong. Also I experienced few times that some applications had black box instead of text (will try to get screenshot next time) – DWM restart helped also ;)

Comparison of AppLocker and SAFER

There is functionality called SAFER (Software Restrictions) in Windows since Windows 2000 (AFAIR)…

If you are familiar with SAFER, you maybe wondered what is difference between software restriction policies and new AppLocker in Windows 7?

Well, main difference is something I wanted long time ago (and even had presentation where I was talking about it) – it’s combination of SAFER and ACT.

In ACT (Application Compatibility Toolkit), you can easily define rules for executables not only based on path\hash (like SAFER), however using all properties of executables – like version, publisher etc…

And that’s major change in AppLocker – now you can not only specify rules based on path and hash, however also using publisher… Which allows you to specify rules using publisher, version of file, product name…

Really nice and much more powerful compared to (restricted) software restrictions :)

Also (don’t exactly remember whether it was possible before), you can specify Allow\Deny rules for AD groups.

Grooveshark is down

Grooveshark just stopped working for me – I am not surprised, after (expected) move by Last.FM (3$ per month) there must be many people searching for alternative…

What I wanted to share with you is page that appeared when you tried to access :)