只是想在一台电脑上运行2个的话很容易,你装2003,远程桌面连到自己,2个用户空间,运行2个肯定可以,如果装不起2003就用2000/XP,也可以勉强啦,去我的BLOG看看多WinStation多桌面... HWINSTA CreateWindowStation( LPTSTR lpwinsta, // new window station name DWORD dwReserved, // reserved; must be zero ACCESS_MASK dwDesiredAccess, // requested access LPSECURITY_ATTRIBUTES lpsa // security attributes ); HDESK CreateDesktop( LPCTSTR lpszDesktop, // name of new desktop LPCTSTR lpszDevice, // reserved; must be NULL LPDEVMODE pDevmode, // reserved; must be NULL DWORD dwFlags, // desktop interaction ACCESS_MASK dwDesiredAccess, // access of returned handle LPSECURITY_ATTRIBUTES lpsa // security attributes ); http://spaces.msn.com/members/UMU625/
CreateMutex()楼上办法应该行不通
HWINSTA CreateWindowStation(
LPTSTR lpwinsta, // new window station name
DWORD dwReserved, // reserved; must be zero
ACCESS_MASK dwDesiredAccess, // requested access
LPSECURITY_ATTRIBUTES lpsa // security attributes
);
HDESK CreateDesktop(
LPCTSTR lpszDesktop, // name of new desktop
LPCTSTR lpszDevice, // reserved; must be NULL
LPDEVMODE pDevmode, // reserved; must be NULL
DWORD dwFlags, // desktop interaction
ACCESS_MASK dwDesiredAccess, // access of returned handle
LPSECURITY_ATTRIBUTES lpsa // security attributes
);
http://spaces.msn.com/members/UMU625/