PC Review Forums Newsgroups Microsoft DotNet Microsoft Dot NET Compact Framework How to create a "EnsureNetwork()" method ?

Reply

How to create a "EnsureNetwork()" method ?

 
Thread Tools Rate Thread
Old 04-10-2005, 02:31 PM   #1
Steve B.
Guest
 
Posts: n/a
Default How to create a "EnsureNetwork()" method ?


Hi,

I'd like some help or good practice in order to make a "EnsureNetwork()"
method.

This method should either check there is network available (typically WIFI)
or connect GPRS connexion (the one configured as default connexion on the
device).

I made some tests, and on my device, a web service call automatically
connect the default connexion. A Sql Ce merge replication synchronize()
method does not. That's why I'd like to ensure the availability of any
network.

I'm also quite confused about networks, destinations and connexions... and I
would appreciate some explanations.

Thanks in advance.
Steve


  Reply With Quote
Old 05-10-2005, 08:33 PM   #2
Paul G. Tobey [eMVP]
Guest
 
Posts: n/a
Default Re: How to create a "EnsureNetwork()" method ?

You'll have to define what device you're running on. If it's a Windows
Mobile device, you can use the Connection Manager, for which there is a
wrapper in OpenNETCF, www.opennetcf.org, to establish a connection, etc.

If you're running on some Windows CE (generic) device, there is no OS
support for ensuring that a network connection exists. You'll have to
figure that out yourself, with knowledge of what connection types are
possible, etc.

Paul T.

"Steve B." <steve_beauge@com.msn.swap_com_and_msn> wrote in message
news:evgE5fOyFHA.1456@TK2MSFTNGP11.phx.gbl...
> Hi,
>
> I'd like some help or good practice in order to make a "EnsureNetwork()"
> method.
>
> This method should either check there is network available (typically
> WIFI) or connect GPRS connexion (the one configured as default connexion
> on the device).
>
> I made some tests, and on my device, a web service call automatically
> connect the default connexion. A Sql Ce merge replication synchronize()
> method does not. That's why I'd like to ensure the availability of any
> network.
>
> I'm also quite confused about networks, destinations and connexions... and
> I would appreciate some explanations.
>
> Thanks in advance.
> Steve
>



  Reply With Quote
Reply



Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off