[Windows API] Programmatically invoking Map Network Drive dialog.

This how the map network drive dialog look like. So how do we show this dialog programmatically? The windows API’s for showing this dialog is: WNetConnectionDialog and WNetConnectionDialog1. I’ve demonstrated both WNetConnectionDialog and WNetConnectionDialog1 in this code snippet. WNetConnectionDialog is a simple API which takes a window handle and a DWORD. While WNetConnectionDialog1 is an […]
Continue reading…

 

Retrieve handle type string using NtQueryObject

Hmm so after a long time I’m back with a new post. This time I came across a cool API called NtQueryObject. One purpose of the API is to find the name of object type it’s given. For example if you are passing a process handle this API will return “Process” as the string. The […]
Continue reading…

 

Capturing mouse input

There are two functions which helps in capturing mouse input, it’s called SetCapture and ReleaseCapture and a helper function called GetCapture which returns a handle to the capture window associated with the current thread. If no window in the thread has captured the mouse, the return value is NULL. Why do we need to capture […]
Continue reading…