Get active wireless network name in MS Access VBA

thenelson used Ask the Experts™
Any suggestions for code to get active wireless network name in MS Access?

BTW: I tried:
the code didn't work.
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Sagar Khatalstudent

set access permission
>set access permission
I don't understand
Distinguished Expert 2017

I'm not sure why that answer was accepted in the thread you linked to.  The code doesn't compile.  The GetWirlessName function is missing.  I tried fixing the spelling error but that didn't fix the issue.
Ensure you’re charging the right price for your IT

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden using our free interactive tool and use it to determine the right price for your IT services. Start calculating Now!

I found the answer at:
The first listing of code on that page starting with:
Option Explicit

Private Const DOT11_SSID_MAX_LENGTH As Long = 32

The function:
returns the name of the active wireless connection.
Distinguished Expert 2017

I forgot to warn you that running Access on a wireless network is dangerous.  Access cannot gracefully recover from network interruptions and they happen frequently on a wireless network.  If they happen at a "bad" time, your BE will be corrupted.
Thanks for the warning but Access is not running on a wireless network. We have two computers running Access each running locally which run a home grown replication routine several times daily to keep the data in sync.  I wanted to know the name of the wireless network to allow activation of routines I only want to run at our office location, not at home.
Distinguished Expert 2017

I didn't test the code so I don't know if it returns all available networks or just the network you are connected to.  If it is just the network you are connected to, then you are running on a wireless network and linking to a Jet/ACE BE over wireless is extremely dangerous.
Nope, as I said, i am not linking to a BE over the network. There are separate BEs local on each computer and I created a replication routine outside of Access that runs several times a day to keep the two BEs in sync. The routine I created is designed to handle network dropouts and I tested it extensively. It has operated flawlessly for about 15 years even if I turn off the computers in the middle of the run.
Distinguished Expert 2017

That's fine.  Since you were asking about wireless networks and Access in the same question, I was just trying to clarify for future readers that running an Access app on a wireless network is dangerous.
I found the answer on anther service.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial