Sign in to follow this  
Followers 0
myth146

disconnect tool?

10 posts in this topic

#1 ·  Posted (edited)

Hi, i dont know if you could do this on autoit but does anyone know if it is possible to make a disconnect tool that disables internet connection and enables it some how on autoit,

thank you.

Edited by myth146

Share this post


Link to post
Share on other sites



Just use ipconfig /release and then ipconfig /renew


Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Share this post


Link to post
Share on other sites

I want to make it for a FPS and put hot keys to enable it and disable it

Share this post


Link to post
Share on other sites

I want to make it for a FPS and put hot keys to enable it and disable it

Was that a question?

[u]Helpful tips:[/u]If you want better answers to your questions, take the time to reproduce your issue in a small "stand alone" example script whenever possible. Also, make sure you tell us 1) what you tried, 2) what you expected to happen, and 3) what happened instead.[u]Useful links:[/u]BrettF's update to LxP's "How to AutoIt" pdfValuater's Autoit 1-2-3 Download page for the latest versions of Autoit and SciTE[quote]<glyph> For example - if you came in here asking "how do I use a jackhammer" we might ask "why do you need to use a jackhammer"<glyph> If the answer to the latter question is "to knock my grandmother's head off to let out the evil spirits that gave her cancer", then maybe the problem is actually unrelated to jackhammers[/quote]

Share this post


Link to post
Share on other sites

Share this post


Link to post
Share on other sites

Put Yashields commands into 2 separate functions, use Hotkeyset() to assign your hotkeys and make a While 1 which sleeps and waits for the hotkeys to be pressed

Share this post


Link to post
Share on other sites

Thanks Yashied.

Share this post


Link to post
Share on other sites

Perhaps this can be of service to you as well. It's a network card en/disable tool that runs in the system tray, but the code can easily be modified or sampled from to suite your needs. Works for XP, but folks have made updates (@ the second link) to work with Vista.

http://www.autoitscript.com/forum/index.ph...st&p=404903

http://www.autoitscript.com/forum/index.ph...st&p=530815

Share this post


Link to post
Share on other sites

#10 ·  Posted (edited)

thanks spudw2k, here's the script.

; Press Esc to terminate script, Pause/Break to "pause"

Global $Paused
HotKeySet("{PAUSE}", "TogglePause")
HotKeySet("{ESC}", "Terminate")
HotKeySet("+!r", "release");Shift-Alt-r
HotKeySet("+!n", "renew");Shift-Alt-n

;;;; Body of program would go here;;;;
While 1
    Sleep(100)
WEnd
;;;;;;;;

Func TogglePause()
    $Paused = NOT $Paused
    While $Paused
        sleep(100)
        ToolTip('Script is "Paused"',0,0)
    WEnd
    ToolTip("")
EndFunc

Func Terminate()
    Exit 0
EndFunc

Func release()
    
Run(@SystemDir & '\ipconfig.exe ' & '/release', @SystemDir, @SW_HIDE)

EndFunc

Func renew()
    
Run(@SystemDir & '\ipconfig.exe ' & '/renew', @SystemDir, @SW_HIDE)

EndFunc
Edited by myth146

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0