Jump to content

AutoItObject UDF help?


step887
 Share

Recommended Posts

so I am trying to do this 

http://msdn.microsoft.com/en-us/library/windows/hardware/ff547694(v=vs.85).aspx

in Autoit

With the autoitobject UDF, there is a _AutoItObject_CoCreateInstance, but the issue is that I can not find CLSID of CLSID_CNetCfg,

The closet I found was http://svn.dsource.org/projects/bindings/trunk/uuid_obj.d

const IID CLSID_CNetCfg = {0x6152035B, 0xF940, 0xD111, [0xAA, 0xEC, 0x00, 0x80, 0x5F, 0xC1, 0x27, 0x0E]};
 

but I am not sure how to translate that into CLSID that can be read by _AutoItObject_CLSIDFromString

Any help is appreciated.

Thanks,

Stephen

 

Link to comment
Share on other sites

Thanks for replying, still having troubles..

so based the below data I created this

$CLSID_CNetCfg = '{6152035B-F940-D111-AAEC-00805FC1270E}'
$IID_INetCfg = '{93AEE8C0-6E30-D111-AACF-00805FC1270E}'
$sTagINetCfg = "Initialize hresult(ptr); Uninitialize hresult(); Apply hresult(); Cancel hresult(); EnumComponents hresults(clsid*;ptr); FindComponent hresults(wstr*;ptr); QueryNetCfgClass hresults(clsid*;ptr;ptr);"
$o = ObjCreateInterface($CLSID_CNetCfg , $IID_INetCfg, $sTagINetCfg); [,"interface_description", ["flag"]] )
If @error Then MsgBox(0,@error,isobj($o))

ObjCreateInterface returns @error of 1

So any help will be appreciated..

 

 

http://msdn.microsoft.com/en-us/library/windows/hardware/ff547694(v=vs.85).aspx

 

HRESULT Initialize(
  [in]  PVOID pvReserved

};

HRESULT Uninitialize(
  void
);HRESULT Apply(
  void
);

HRESULT Cancel(
  void
);
HRESULT EnumComponents(
  [in]             const GUID *pguidClass,
  [out, optional]  IEnumNetCfgComponent **ppenumComponent
);
HRESULT FindComponent(
  [in]             LPCWSTR pszwComponentId,
  [out, optional]  INetCfgComponent **ppComponent
);

HRESULT QueryNetCfgClass(
  [in]             const GUID *pguidClass,
  [in]             REFIID riid,
  [out, optional]  void **ppvObject
);



 

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...