0

Hello,

I am writing a program in C++ to open a web page in a browser using command line.

Suppose, I enter open www.google.com

It should open Google's home page in a browser. I want to make this program multithreaded so a user can open as many web pages as possible.

I tried google search for it, and it appears that I would need to create a batch file to do so. I am not sure how to work with batch files, so I do not think it is a probable solution.

Thanks,

2
Contributors
2
Replies
4
Views
8 Years
Discussion Span
Last Post by computerages
0

I would probably recommend the use of the curl library as way for your program to interface with the internet.

As far as multithreading goes.. it may be possible to open web pages on demand from the user as the user initiates the action; therefore, I would explore the possibility of event-driven launch of webpages before unnecessary multi-threading.

0

Hi,

I actually found an easier approach to solve this problem:

system("start firefox.exe www.example.com"); // firefox.exe can be replaced with iexplorer.exe

This is accomplished without using curl library, or multithreading functions.

Thanks for the help.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.