Can not simulate Win+D on Metro UI in Windows 8?
Locked
-
quinta-feira, 2 de agosto de 2012 02:08
I want to switch Metro UI to desktop. Simulate Win+D can work on traditional desktop, but can not work on Metro UI. Code as below:
keybd_event(VK_LWIN, MapVirtualKeyEx(VK_LWIN,0,GetKeyboardLayout(0)), 0, 0);
Sleep(30);
keybd_event(VK_D ,MapVirtualKeyEx(VK_D,0,GetKeyboardLayout(0)) , 0, 0);
Sleep(30);
keybd_event(VK_D , MapVirtualKeyEx(VK_D,0,GetKeyboardLayout(0)) , KEYEVENTF_KEYUP,0);
Sleep(30);
keybd_event(VK_LWIN, MapVirtualKeyEx(VK_LWIN,0,GetKeyboardLayout(0)), KEYEVENTF_KEYUP,0);Win+C can work well. Please tell me why it can not work well.
- Movido Jesse JiangMicrosoft Contingent Staff, Moderator sexta-feira, 3 de agosto de 2012 06:03 (From:Visual C++ MFC and ATL)
Todas as Respostas
-
sexta-feira, 3 de agosto de 2012 06:09
Hi,
Welcome to the MSDN forum.
Based on your description, your issue is about Metro API, so I’d like to move this thread to Building Metro style apps with C++ for better support, since here is for C++ general.
Thanks for your understanding.
Regards,
Elegentin
Elegentin Xie [MSFT]
MSDN Community Support | Feedback to us
-
sexta-feira, 3 de agosto de 2012 20:38Moderador
Locking this as a duplicate of Can not simulate Win+D on Metro UI in Windows 8? in the Application Compatibility for Windows Desktop Development Forum.
Since the question is about writing a desktop app it is off topic in the Building Metro style apps with C++ forum.
--Rob
- Marcado como Resposta Rob CaplanMicrosoft Employee, Moderator sexta-feira, 3 de agosto de 2012 20:41

