开发者

GPRS connection watchdog

开发者 https://www.devze.com 2023-01-13 05:42 出处:网络
I\'d like to make my WM-based device reconnect to GPRS network, if connection has been broken. There is a function in WinAPI

I'd like to make my WM-based device reconnect to GPRS network, if connection has been broken.

There is a function in WinAPI

HRESULT WINAPI ConnMgrConnectionStatus(
  HANDLE  hConnection,
  DWORD   *pdwStatus
); 

but it requires previous connection handle, and in my case it开发者_C百科 can be established manually.

Is there a way to get connection status without handles or subscribe to break event?

I can just check google.com, but that doesn't look good.

Regards,


Why can't you use the ConnMgrQueryDetailedStatus to get all the connections and run through them to check what you have?

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号