473,466 Members | 1,401 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Detecting Internet Connection

Is there any way to detect Dial-up Internet connection using .NET libraries
or do I have to use Win APIs for that?
Nov 20 '05 #1
4 1016
* "Adam Tibi" <at***@DONTSPAMME.terra.net.lb> scripsit:
Is there any way to detect Dial-up Internet connection using .NET libraries
or do I have to use Win APIs for that?


There is currently no managed way to do that available in the Framework.

--
Herfried K. Wagner [MVP]
<URL:http://dotnet.mvps.org/>
Nov 20 '05 #2
Hai Adam

There is an API to check whether you have the internet connection are not. But i dont' remember it right now. I have used that in some part of my project. I will mail u that.

Sadha Sivam
Malleable Minds Software Pvt Ltd.
sa************@yahoo.com
Nov 20 '05 #3
Hi Adam

Check with this api

'API method to check for the internet connectio
Public Declare Function InternetCheckConnection Lib "wininet.dll" Alias "InternetCheckConnectionA" (ByVal lpszUrl As String, ByVal dwFlags As Integer, ByVal dwReserved As Integer) As Intege
Public Const FLAG_ICC_FORCE_CONNECTION As Short = &H1

Where it takes the URL you want to check

Sadha Sivam
Malleable Minds Software Pvt Ltd.

Nov 20 '05 #4

if lpszUrl is null and the flag is false can this be used to see if there
is any connection at all ??
Excuse for butting in!
"Sadha Sivam S" <sadhasiavm1981> wrote in message
news:C4**********************************@microsof t.com...
Hi Adam,

Check with this api,

'API method to check for the internet connection
Public Declare Function InternetCheckConnection Lib "wininet.dll" Alias "InternetCheckConnectionA" (ByVal lpszUrl As String, ByVal dwFlags As
Integer, ByVal dwReserved As Integer) As Integer Public Const FLAG_ICC_FORCE_CONNECTION As Short = &H1S

Where it takes the URL you want to check.

Sadha Sivam S
Malleable Minds Software Pvt Ltd.,

Nov 20 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Matt Hawley | last post by:
I'm facing a problem where I need to verify that my windows forms application has access to the internet before it can do anything. Currently, the only way I can think of is by creating a...
4
by: Peter Flynn | last post by:
I'm having trouble finding example code to detect the presence of an Internet connection. It doesn't seem to be a very frequently asked question, as all I need is the answer yes or no (is the user...
3
by: Graeme Hinchliffe | last post by:
Hiya I have now managed to get my code to function correctly for a none present db, and one that is shutdown whilst it is being used. In both cases my code functions and happily recovers on the...
0
Ali Rizwan
by: Ali Rizwan | last post by:
Hi all, I m facing a big problem... How can i detect that either the internet connection id dialup or is on LAN or is their both connection exists...... and what is the connection speed. And is...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.