AlienStar Posted September 28, 2010 Share Posted September 28, 2010 (edited) hello everybody as we know we can see data sent and received when we select the properties of the internet connection how can I detect bytes of data sent and received during internet connection ? thanks Edited September 28, 2010 by AlienStar Link to comment Share on other sites More sharing options...
PsaltyDS Posted September 28, 2010 Share Posted September 28, 2010 There are counters like Win32_PerfFormattedData_Tcpip_NetworkInterface in WMI that AutoIt can use via the COM interface. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
Ascend4nt Posted September 28, 2010 Share Posted September 28, 2010 (edited) Try Network Usage (bytes sent/received) using my Performance Counters UDF. Any WMI interface with Win32_Perf is probably available (in a faster form) using my UDF.*edit: actually, that's for overall network performance. There are however Performance Counters for things like IP, TCP and UDP that could possibly be used to calculate the network performance.. though I'm not sure what 'segments/datagrams per second' means in terms of bytes Edited September 28, 2010 by Ascend4nt My contributions: Performance Counters in Windows - Measure CPU, Disk, Network etc Performance | Network Interface Info, Statistics, and Traffic | CPU Multi-Processor Usage w/o Performance Counters | Disk and Device Read/Write Statistics | Atom Table Functions | Process, Thread, & DLL Functions UDFs | Process CPU Usage Trackers | PE File Overlay Extraction | A3X Script Extract | File + Process Imports/Exports Information | Windows Desktop Dimmer Shade | Spotlight + Focus GUI - Highlight and Dim for Eyestrain Relief | CrossHairs (FullScreen) | Rubber-Band Boxes using GUI's (_GUIBox) | GUI Fun! | IE Embedded Control Versioning (use IE9+ and HTML5 in a GUI) | Magnifier (Vista+) Functions UDF | _DLLStructDisplay (Debug!) | _EnumChildWindows (controls etc) | _FileFindEx | _ClipGetHTML | _ClipPutHTML + ClipPutHyperlink | _FileGetShortcutEx | _FilePropertiesDialog | I/O Port Functions | File(s) Drag & Drop | _RunWithReducedPrivileges | _ShellExecuteWithReducedPrivileges | _WinAPI_GetSystemInfo | dotNETGetVersions | Drive(s) Power Status | _WinGetDesktopHandle | _StringParseParameters | Screensaver, Sleep, Desktop Lock Disable | Full-Screen Crash Recovery Wrappers/Modifications of others' contributions: _DOSWildcardsToPCRegEx (original code: RobSaunder's) | WinGetAltTabWinList (original: Authenticity) UDF's added support/programming to: _ExplorerWinGetSelectedItems | MIDIEx UDF (original code: eynstyne) (All personal code/wrappers centrally located at Ascend4nt's AutoIT Code) Link to comment Share on other sites More sharing options...
PsaltyDS Posted September 28, 2010 Share Posted September 28, 2010 You could also go with a loop of command lines like this: netstat -p IP -s and parse the outputs. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
AlienStar Posted September 29, 2010 Author Share Posted September 29, 2010 (edited) Try Network Usage (bytes sent/received) using my Performance Counters UDF. Any WMI interface with Win32_Perf is probably available (in a faster form) using my UDF.*edit: actually, that's for overall network performance. There are however Performance Counters for things like IP, TCP and UDP that could possibly be used to calculate the network performance.. though I'm not sure what 'segments/datagrams per second' means in terms of bytesthanks Ascend4nt for helpI test this code :Example #5: Network Usagebut I faced a problem :when I run the script it send Error :Line 291 (File "C:\Program Files(x86)\Autoit3\Include\_PDH_PerformanceCounters.au3"):OnAutoItExitRegister("_PDH_UnInit")^ERRORError : Unknown function name .Note : I use windows 7 x64 home premium so please help meAlso PsaltyDS thanks for help but would you explain more Edited September 29, 2010 by AlienStar Link to comment Share on other sites More sharing options...
Ascend4nt Posted September 29, 2010 Share Posted September 29, 2010 (edited) AlienStar, First, please edit your post and remove my code from it. Its part of my license agreement, which brings me to my second point: You must download the actual UDF. I posted a link to the example. The UDF is linked to in the first post in that thread (that's where you'll see the License agreement). You can simply click the link in my signature for it. *edit: err.. it looks like you didn't extract the files properly actually. Make sure you extract them with their own subfolders. Remember also the example is for network usage, not specifically internet usage. thanks Edited September 29, 2010 by Ascend4nt My contributions: Performance Counters in Windows - Measure CPU, Disk, Network etc Performance | Network Interface Info, Statistics, and Traffic | CPU Multi-Processor Usage w/o Performance Counters | Disk and Device Read/Write Statistics | Atom Table Functions | Process, Thread, & DLL Functions UDFs | Process CPU Usage Trackers | PE File Overlay Extraction | A3X Script Extract | File + Process Imports/Exports Information | Windows Desktop Dimmer Shade | Spotlight + Focus GUI - Highlight and Dim for Eyestrain Relief | CrossHairs (FullScreen) | Rubber-Band Boxes using GUI's (_GUIBox) | GUI Fun! | IE Embedded Control Versioning (use IE9+ and HTML5 in a GUI) | Magnifier (Vista+) Functions UDF | _DLLStructDisplay (Debug!) | _EnumChildWindows (controls etc) | _FileFindEx | _ClipGetHTML | _ClipPutHTML + ClipPutHyperlink | _FileGetShortcutEx | _FilePropertiesDialog | I/O Port Functions | File(s) Drag & Drop | _RunWithReducedPrivileges | _ShellExecuteWithReducedPrivileges | _WinAPI_GetSystemInfo | dotNETGetVersions | Drive(s) Power Status | _WinGetDesktopHandle | _StringParseParameters | Screensaver, Sleep, Desktop Lock Disable | Full-Screen Crash Recovery Wrappers/Modifications of others' contributions: _DOSWildcardsToPCRegEx (original code: RobSaunder's) | WinGetAltTabWinList (original: Authenticity) UDF's added support/programming to: _ExplorerWinGetSelectedItems | MIDIEx UDF (original code: eynstyne) (All personal code/wrappers centrally located at Ascend4nt's AutoIT Code) Link to comment Share on other sites More sharing options...
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