Here's a tip from Paul Adare (author of Paul's Digital Lounge and Cigar Bar). If you want an application to discover it's running in a virtual machine, you can do the following:
You could query the registry for the existence of the HKLM\SOFTWARE\Microsoft\Virtual Machine key. Or you could use an WMI query, such as this:
On Error Resume Next
strComputer = "."
Set objWMIService = GetObject("winmgmts:\\" & strComputer & "\root
Set colItems = objWMIService.ExecQuery("Select * from Win32
For Each objItem in colItems
if objitem.Product = "Virtual Machine"