Open a URL in C++

December 2016



Issue


How to open a link (URL) contained in a string, in C++?

Solution


Try this:
#include <windows.h>
.
char* linkChar="http://www.google.com";
.
ShellExecute(NULL, NULL, linkChar, NULL, NULL, SW_SHOWNORMAL);



elcactus75 for this tip!

Related :

This document entitled « Open a URL in C++ » from CCM (ccm.net) is made available under the Creative Commons license. You can copy, modify copies of this page, under the conditions stipulated by the license, as this note appears clearly.