I am new to powershell, have completed the 6 hours course recently, i am currently developing small tool, i want to check our vpn status whether connected or not,
i have used
gwmi win32_networkadapterconfiguration -Filter ‘Description=“MyVPN Adapter”’ | ft IPEnabled
Shows as false even if the vpn is connected, how to detect the status, please help me out.
Thanks in advance