Check if on wireless network

N

neshev

Hi Guys. I have created a standalone database for a client that is set up on
all their laptops. Their employees enter information onto the database on the
laptop and when they return to the office they sign off the information and
it transfers over the wireless network to the Master database on the server.
At the moment, each employee is asked when logging on whether they are in the
office or outside. if they are in the office, the information transfers. Does
anybody know how to check whether the computer is connected to the wireless
network by using code rather than asking. If this can be done, the data can
automatically transfer when the database is opened and new schedule
information can be uploaded to the laptop. so I need code to search for a
specified connected network. Any help with this will be great

Thanks

NS
 
6

'69 Camaro

Hi.
I have created a standalone database for a client that is set up on
all their laptops. Their employees enter information onto the database on
the
laptop and when they return to the office they sign off the information
and
it transfers over the wireless network to the Master database on the
server.

Allowing an Access database to connect to another database file via a
wireless network is a recipe for corrupted database files. It is not
recommended. Use Ethernet cables to connect the laptops to the office
network.

HTH.
Gunny

See http://www.QBuilt.com for all your database needs.
See http://www.Access.QBuilt.com for Microsoft Access tips and tutorials.
Blogs: www.DataDevilDog.BlogSpot.com, www.DatabaseTips.BlogSpot.com
http://www.Access.QBuilt.com/html/expert_contributors2.html for contact
info.
 
N

neshev

Thanks Gunny.
My question was - is there a way that the database can check if the network
is connected to the laptop. So if the ethernet cable is connected, is there a
way that the database can detect that the server is available. The database
is stored on the C drive of the laptops and only connects to the server when
transferring data.

regards

neil
 
D

David W. Fenton

Allowing an Access database to connect to another database file
via a wireless network is a recipe for corrupted database files.
It is not recommended. Use Ethernet cables to connect the laptops
to the office network.

If you use indirect replication to transfer the data, there's no
danger on a wireless LAN (or over a WAN, for that matter).
 
D

David W. Fenton

My question was - is there a way that the database can check if
the network is connected to the laptop. So if the ethernet cable
is connected, is there a way that the database can detect that the
server is available. The database is stored on the C drive of the
laptops and only connects to the server when transferring data.

After my sig is code that should be usable in any application with
no added references. If you want to check for a file instead, change
the objFSO.FolderExists to objFSO.FileExists and supply a filename
as the argument, instead.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/

Public Function CheckForNetwork(strFolderToCheck As String, _
Optional bolClear As Boolean = False) As Boolean
Static objFSO As Object 'late binding

If bolClear Then Set objFSO = Nothing: Exit Function

If objFSO Is Nothing Then
Set objFSO = CreateObject("Scripting.FileSystemObject")
End If
If objFSO.FolderExists(strFolderToCheck) Then
CheckForNetwork = True
Else
MsgBox "Not connected to the network!", vbExclamation, _
"Not connected"
End If
End Function
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top