Get url opened by Google Chrome's main window

This is a small example of invoking Win32 API. It gets the url which is opened by Google chrome's main window.