Detect When Network Cable Unplugged(检测何时拔下网线)
问题描述
Windows 知道您何时从 NIC 上拔掉了网线.有没有一种编程方式可以通过 C++ 中的 API 来确定这一点?
注意:我没有使用 .NET,这是用于封闭 LAN(从未连接到 Internet)
Raymond Chen 博客 最近关于类似的事情.这是相关的文档.我认为 MIB_IPADDR_DISCONNECTED 标志正是您要找的.p>
Windows knows when you have removed the network cable from your NIC. Is there a programmatic way to determine this via API in C++?
Note: I am not using .NET and this is for a closed LAN (not connected to Internet ever)
Raymond Chen blogged about something similar recently. Here is the relevant documentation. I think the MIB_IPADDR_DISCONNECTED flag is what you are looking for.
这篇关于检测何时拔下网线的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:检测何时拔下网线


- 如何对自定义类的向量使用std::find()? 2022-11-07
- 与 int by int 相比,为什么执行 float by float 矩阵乘法更快? 2021-01-01
- 使用/clr 时出现 LNK2022 错误 2022-01-01
- Stroustrup 的 Simple_window.h 2022-01-01
- STL 中有 dereference_iterator 吗? 2022-01-01
- 静态初始化顺序失败 2022-01-01
- C++ 协变模板 2021-01-01
- 从python回调到c++的选项 2022-11-16
- 一起使用 MPI 和 OpenCV 时出现分段错误 2022-01-01
- 近似搜索的工作原理 2021-01-01