c++ - How do I use the windows network API in Qt? -


i going put network status icon in gui application. network status notification, trying use windows api. thinking use networkavailabilitychangedeventhandler in application. new programming windows api , framework. can me in following things:

  1. can api networkavailabilitychangedeventhandle used in c#?
  2. can use in c++ (qt)?
  3. which header file must include? (i checked in msdn this. using namespace this. examples in c#. not able understand how implement in c++ code.)

i grateful if can give me detailed code snippet using windows event handler, including .h file or namespace included.

where did idea use networkavailabilitychangedeventhandler delegate?

that explicitly not part of windows api, rather delegate function used .net framework in conjunction networkchange.networkavailabilitychanged event. explains why examples on msdn in c#—because intended used in applications targeting .net framework. if you're writing unmanaged c++ using qt, you're not using .net framework, , can't take advantage of functionality.


windows api equivalent internetgetconnectedstate function, returns value indicating whether or not system connected internet. you'll find msdn documentation substantially friendlier towards unmanaged c++ developers, because that's the
primary intended audience. information you're seeking given @ bottom:

header          wininet.h

library           wininet.lib

dll                 wininet.dll

you can find list of wininet functions here.


Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

c# - How to add a new treeview at the selected node? -

java - netbeans "Please wait - classpath scanning in progress..." -