Click here to Skip to main content
12,357,929 members (67,354 online)
   

C#

 
GeneralRe: How to reference .net DLL present in other folder Pin
Alan N2-Jan-13 8:51
memberAlan N2-Jan-13 8:51 
GeneralRe: How to reference .net DLL present in other folder Pin
KASR18-Jan-13 8:00
memberKASR18-Jan-13 8:00 
QuestionRe: How to reference .net DLL present in other folder Pin
PIEBALDconsult26-Dec-12 9:13
memberPIEBALDconsult26-Dec-12 9:13 
AnswerRe: How to reference .net DLL present in other folder Pin
KASR126-Dec-12 16:25
memberKASR126-Dec-12 16:25 
QuestionUsage of Google API in windows application Pin
ukraju24-Dec-12 1:05
memberukraju24-Dec-12 1:05 
AnswerRe: Usage of Google API in windows application Pin
frazzle-me24-Dec-12 2:25
memberfrazzle-me24-Dec-12 2:25 
AnswerRe: Usage of Google API in windows application Pin
Sajeesh Payolam24-Dec-12 20:28
memberSajeesh Payolam24-Dec-12 20:28 
QuestionDetecting a 3G connection in Windows 7 and 8 in a desktop application Pin
REDSERPENT724-Dec-12 1:04
memberREDSERPENT724-Dec-12 1:04 
Hi

I am in the process of developing a cloud backup software. The application is a desktop application developed using C#.

I need to add an option to stop/pause the backup if the computer was connected to a 3G network to save cost for the user.

I cannot seem to be able to find any example on how this can be achieved, there are some examples for Windows Phone and Windows Store Apps but I cannot find anything that can check if the connection type is a WiFi/Ethernet or 3G the latter is my main concern.

I tried a test application to enumerate the networks:

Console.WriteLine("checking network interfaces\n");
 
NetworkInterface[] interfaces =  NetworkInterface.GetAllNetworkInterfaces();
 
foreach (var networkInterface in interfaces)
{
   Console.WriteLine("Interface Detected");
   Console.WriteLine("Description: "+networkInterface.Description);
   Console.WriteLine("ID: " + networkInterface.Id);
   Console.WriteLine("Name: " + networkInterface.Name);
   Console.WriteLine("Interface Type: " + networkInterface.NetworkInterfaceType);
   Console.WriteLine("Operational Status: " + networkInterface.OperationalStatus.ToString());
   Console.WriteLine("Speed: " + networkInterface.Speed.ToString());
   Console.WriteLine("Supports Multicast: " + networkInterface.SupportsMulticast.ToString());
   Console.WriteLine("#########################################################\n");
}
The above code list my 3G connection as PPP which can be either ADSL or 3G. I am not sure if I can differentiate using some other options or APIs

I need a clear way to distinguish between those networks and so far I cannot find a way of doing so.

Can someone please help?

modified 24-Dec-12 7:12am.

AnswerRe: Detecting a 3G connection in Windows 7 and 8 in a desktop application Pin
MaulikDusara24-Dec-12 20:44
memberMaulikDusara24-Dec-12 20:44 
GeneralRe: Detecting a 3G connection in Windows 7 and 8 in a desktop application Pin
REDSERPENT729-Dec-12 21:33
memberREDSERPENT729-Dec-12 21:33 
QuestionIpstatus.Success answer twice !! Pin
Alex1971_rm24-Dec-12 0:15
memberAlex1971_rm24-Dec-12 0:15 
QuestionHow do i create an object of partial class in user control Pin
swapnil709022-Dec-12 20:27
memberswapnil709022-Dec-12 20:27 
AnswerRe: How do i create an object of partial class in user control Pin
nainakarri22-Dec-12 22:03
membernainakarri22-Dec-12 22:03 
Questionerror i declaring null arrays Pin
tashee22-Dec-12 5:22
membertashee22-Dec-12 5:22 
AnswerRe: error i declaring null arrays Pin
Richard MacCutchan22-Dec-12 6:40
mvpRichard MacCutchan22-Dec-12 6:40 
GeneralRe: error i declaring null arrays Pin
tashee22-Dec-12 7:39
membertashee22-Dec-12 7:39 
GeneralRe: error i declaring null arrays Pin
PIEBALDconsult22-Dec-12 8:11
memberPIEBALDconsult22-Dec-12 8:11 
GeneralRe: error i declaring null arrays Pin
harold aptroot24-Dec-12 0:52
memberharold aptroot24-Dec-12 0:52 
QuestionWorking with data base Pin
columbos1492722-Dec-12 4:26
membercolumbos1492722-Dec-12 4:26 
AnswerRe: Working with data base Pin
PIEBALDconsult22-Dec-12 5:07
memberPIEBALDconsult22-Dec-12 5:07 
GeneralRe: Working with data base Pin
SledgeHammer0122-Dec-12 9:38
memberSledgeHammer0122-Dec-12 9:38 
GeneralRe: Working with data base Pin
PIEBALDconsult22-Dec-12 12:58
memberPIEBALDconsult22-Dec-12 12:58 
GeneralRe: Working with data base Pin
jschell22-Dec-12 14:05
memberjschell22-Dec-12 14:05 
GeneralRe: Working with data base Pin
Simon_Whale23-Dec-12 0:05
memberSimon_Whale23-Dec-12 0:05 
AnswerRe: Working with data base Pin
Abhinav S25-Dec-12 4:49
mvpAbhinav S25-Dec-12 4:49 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.


Advertise | Privacy | Mobile
Web02 | 2.8.160621.1 | Last Updated 30 Jun 2016
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid