// declare a função :
function conexao_teste : boolean;
// implemente função :
function conexao_teste : Boolean;
var
flags : DWORD;
begin
if not InternetGetConnectedState(@flags, 0) then
result := false
else
result := true;
end;
// para a verificação :
conexao_teste;
if conexao_teste = true then showmessage ('conectado');
Nenhum comentário:
Postar um comentário