Ibrahim Posted March 13, 2008 Posted March 13, 2008 Helped me. Hope it helps you and Any refinements are welcome expandcollapse popup#Include<Array.au3> #include <file.au3> #include <GuiConstantsEx.au3> #include <GuiIPAddress.au3> #include <Process.au3> ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;get ip address;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; _RunDOS ("ipconfig >c:\ipcon.dat") ProcessWaitClose("ipconfig.exe") Dim $iRecords If Not _FileReadToArray("c:\ipcon.dat",$iRecords) Then MsgBox(4096,"Error", " Error reading log to Array error:" & @error) Exit EndIf $iPos = _ArraySearch ($iRecords, "Gateway", 0, 0, 0, True) $gatewayIP=$iRecords[$iPos] $gatewayIP=StringTrimLeft($gatewayIP,44) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;Mac Addressssssss;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; _RunDOS ("arp -a >c:\arp.dat") ProcessWaitClose("arp.exe") Dim $mRecords If Not _FileReadToArray("c:\arp.dat",$mRecords) Then MsgBox(4096,"Error", " Error reading log to Array error:" & @error) Exit EndIf $Pos = _ArraySearch ($mRecords,$gatewayIP, 0, 0, 0, True) $gatewaymac=$mRecords[$Pos] $gatewaymac=StringTrimLeft($gatewaymac,24) if StringRight($gatewaymac,10)="dynamic " then $gatewaymac=StringTrimRight($gatewaymac,15) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;Ip Address Controlllllllll;;;;;;;;;;;;;;;;;;;;;; $hgui = GUICreate("Ibrahim Ghorabah Connection detection", 300, 100) GUICtrlCreateGroup ("GateWay Information (Router)", 10,10,280, 80) $hIPAddress = _GUICtrlIpAddress_Create ($hgui, 120,30) GUISetState(@SW_SHOW) _GUICtrlIpAddress_Set ($hIPAddress,$gatewayIP) GUICtrlCreateInput($gatewaymac,120,60,130,25,$ES_CENTER+$ES_LOWERCASE) GUICtrlSetFont (-1,9, 800, 0,"Tahoma") Do Until GUIGetMsg() = $GUI_EVENT_CLOSE [font="Arial Black"]My Stuff[/font]UPnP Port Forwarding Final.GateWay InformationThe GateWay Watcher(detect speeofing)Rightclick Any file --->Hide/UnhideThe Tip WatcherA PanelShare WatcherThe Arp WatcherThe Online License Checker
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now