Please help!!!!! When I use this code in excel base vb in my remote desktop - its not capturing the image , but opening a popup window that gives the save as option. Another messeg window comes along stating "Printing the screen print to Microsoft office document Image writer on Ne00. - A product of american system.'

please help. the code I used for taking screen shot is as follows:



Option Explicit Private Declare Sub keybd_event Lib "user32" (ByVal bVk As Byte, ByVal bScan As Byte, _ByVal dwFlags As Long, ByVal dwExtraInfo As Long) Private Const VK_SNAPSHOT = &H2C

private sub commandbutton_click()

Call keybd_event(vbKeySnapshot, 1, 0, 0)


End sub