Last active
January 25, 2019 07:54
-
-
Save abhimanyu003/d349a7c21a0d689e83d2 to your computer and use it in GitHub Desktop.
Turns your Laptop/PC into a WiFi hotspot. Make sure to "Run as Admin"
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
title Wifi Hotspot | |
echo What You What To Do ? | |
echo 1 to create wifi | |
echo 2 to stop wifi | |
echo 3 show details | |
set /p input= | |
if %input%==1 goto 1 | |
if %input%==2 goto 2 | |
if %input%==3 goto 3 | |
:1 | |
cls | |
setlocal | |
set ssid=%RANDOM% | |
netsh wlan set hostednetwork mode=allow ssid=%ssid% key=am12345678 >null | |
netsh wlan start hostednetwork | |
echo Wifi is started with name "%ssid%" and password am12345678 | |
pause >null | |
exit; | |
:2 | |
cls | |
netsh wlan stop hostednetwork >null | |
netsh wlan set hostednetwork mode=disallow | |
pause >null | |
exit; | |
:3 | |
cls | |
netsh wlan show hostednetwork | |
pause >null | |
exit; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment