First, to determine whether you have been linked to the Internet
Read the local IP address using the Netmasters powersock control, if the "0.0.0.0" description is not connected.
Example:
void __fastcall TForm1::Button1Click(TObject *Sender)
{
if (Powersock1->LocalIP == "0.0.0.0")
ShowMessage("not connected");
else
ShowMessage(Powersock1->LocalIP);
Second, the issue of dialing
1, dial-up
You need to use the following telephony API.
function function
Lineinitializeex () Initialization of TAPI
Lineopen () get an available phone line handle (handle)
Linemakecall () Start dialing
To complete sending data outside of TAPI
Linedrop (),
Linedeallocatecall (),
Lineclose ().
Lineshutdown () End dialing
Third, call the browser
1.头文件:#include <shellapi.h>
2.void __fastcall TForm1::Button1Click(TObject *Sender)
{
ShellExecute(Application->Handle,"open",
"http://www.inprise.com",NULL,NULL,SW_SHOW);
}