By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,773 Members | 1,779 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,773 IT Pros & Developers. It's quick & easy.

connection event

P: n/a
is there some kind of an event that starts when I establish a
connection to internet?

Apr 27 '07 #1
Share this Question
Share on Google+
5 Replies


P: n/a
No, not really. A good number of users are connected to the internet
all the time now from home (either behind a firewall/NAT router or directly
connected to a cable modem which is always on), or they are at work, in
which case they access the internet through proxy servers, and are always
connected to their internal network. Such an event would almost never get
fired.

What are you trying to do?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

<wa*********@gmail.comwrote in message
news:11**********************@t38g2000prd.googlegr oups.com...
is there some kind of an event that starts when I establish a
connection to internet?

Apr 27 '07 #2

P: n/a
It is a program that runs in the background and turns on the proxy in
IE when Im in school. Right now I have a timer that check the
connection every second, and that fells kind of lame ^^
On 27 Apr, 18:21, "Nicholas Paldino [.NET/C# MVP]"
<m...@spam.guard.caspershouse.comwrote:
No, not really. A good number of users are connected to the internet
all the time now from home (either behind a firewall/NAT router or directly
connected to a cable modem which is always on), or they are at work, in
which case they access the internet through proxy servers, and are always
connected to their internal network. Such an event would almost never get
fired.

What are you trying to do?

--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com

<warborns...@gmail.comwrote in message

news:11**********************@t38g2000prd.googlegr oups.com...
is there some kind of an event that starts when I establish a
connection to internet?- Dölj citerad text -

- Visa citerad text -

Apr 27 '07 #3

P: n/a
Well, yes, that's going to kill your computer's performance running it
like that.

Why not just have a script or something which will change your proxy
settings when you are at school, and another one to set them back when you
are at home?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

<wa*********@gmail.comwrote in message
news:11**********************@b40g2000prd.googlegr oups.com...
It is a program that runs in the background and turns on the proxy in
IE when Im in school. Right now I have a timer that check the
connection every second, and that fells kind of lame ^^
On 27 Apr, 18:21, "Nicholas Paldino [.NET/C# MVP]"
<m...@spam.guard.caspershouse.comwrote:
No, not really. A good number of users are connected to the internet
all the time now from home (either behind a firewall/NAT router or
directly
connected to a cable modem which is always on), or they are at work, in
which case they access the internet through proxy servers, and are always
connected to their internal network. Such an event would almost never get
fired.

What are you trying to do?

--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com

<warborns...@gmail.comwrote in message

news:11**********************@t38g2000prd.googlegr oups.com...
is there some kind of an event that starts when I establish a
connection to internet?- Dölj citerad text -

- Visa citerad text -


Apr 27 '07 #4

P: n/a
I don't think that is a *bad* solution. It's one of the problems where "how
else would you do it?" If there was an event from the OS it would be
triggered via the same method most likely; polling the connection every set
interval.

If you want to detect a physical connection I think you can query the
adapter for it's connection state (IE: cable unplugged)
<wa*********@gmail.comwrote in message
news:11**********************@b40g2000prd.googlegr oups.com...
It is a program that runs in the background and turns on the proxy in
IE when Im in school. Right now I have a timer that check the
connection every second, and that fells kind of lame ^^

On 27 Apr, 18:21, "Nicholas Paldino [.NET/C# MVP]"
<m...@spam.guard.caspershouse.comwrote:
No, not really. A good number of users are connected to the internet
all the time now from home (either behind a firewall/NAT router or
directly
connected to a cable modem which is always on), or they are at work, in
which case they access the internet through proxy servers, and are always
connected to their internal network. Such an event would almost never get
fired.

What are you trying to do?

--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com

<warborns...@gmail.comwrote in message

news:11**********************@t38g2000prd.googlegr oups.com...
is there some kind of an event that starts when I establish a
connection to internet?- Dölj citerad text -

- Visa citerad text -


Apr 27 '07 #5

P: n/a
I don't really understand what it is you are trying to accomplish (I'm
sleepy ;) but if you need to take action when you change locations, maybe
the adapter status query would solve your problem efficiently. When you
detect a connection is physically lost set a flag, keep polling the
connection state, when the connection state indicates you have a phys.
connection again run some net utils to try and determine what network you
are, then take appropriate action.

Like I said, I don't really understand what you want to do so the above
suggestion could be garbage!

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard.caspershouse.comwrote in
message news:O5**************@TK2MSFTNGP06.phx.gbl...
Well, yes, that's going to kill your computer's performance running it
like that.

Why not just have a script or something which will change your proxy
settings when you are at school, and another one to set them back when you
are at home?
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard.caspershouse.com

<wa*********@gmail.comwrote in message
news:11**********************@b40g2000prd.googlegr oups.com...
It is a program that runs in the background and turns on the proxy in
IE when Im in school. Right now I have a timer that check the
connection every second, and that fells kind of lame ^^
On 27 Apr, 18:21, "Nicholas Paldino [.NET/C# MVP]"
<m...@spam.guard.caspershouse.comwrote:
> No, not really. A good number of users are connected to the internet
all the time now from home (either behind a firewall/NAT router or
directly
connected to a cable modem which is always on), or they are at work, in
which case they access the internet through proxy servers, and are always
connected to their internal network. Such an event would almost never
get
fired.

What are you trying to do?

--
- Nicholas Paldino [.NET/C# MVP]
- m...@spam.guard.caspershouse.com

<warborns...@gmail.comwrote in message

news:11**********************@t38g2000prd.googleg roups.com...
is there some kind of an event that starts when I establish a
connection to internet?- Dölj citerad text -

- Visa citerad text -



Apr 27 '07 #6

This discussion thread is closed

Replies have been disabled for this discussion.