tag:blogger.com,1999:blog-1053373784078711683.post7018755382853540297..comments2022-07-21T13:39:37.365-07:00Comments on WinCE: Controlling an Ethernet Adapter using Power Manager APIVaisakh P Shttp://www.blogger.com/profile/02782445552012217777noreply@blogger.comBlogger4125tag:blogger.com,1999:blog-1053373784078711683.post-80349447079628892512008-11-15T21:47:00.000-08:002008-11-15T21:47:00.000-08:00here is the code for DoNdisIOControlBOOL DoNdisIOC...here is the code for DoNdisIOControl<BR/><BR/>BOOL DoNdisIOControl(DWORD dwCommand, LPVOID pInBuffer,DWORD cbInBuffer, LPVOID pOutBuffer,DWORD * pcbOutBuffer)<BR/>{<BR/> HANDLE hNdis;<BR/> BOOL fResult = FALSE;<BR/><BR/> hNdis = ::CreateFile(DD_NDIS_DEVICE_NAME, GENERIC_READ |GENERIC_WRITE,FILE_SHARE_READ | FILE_SHARE_WRITE, NULL, OPEN_ALWAYS,0, NULL);<BR/> if (INVALID_HANDLE_VALUE != hNdis)<BR/> {<BR/> fResult = ::DeviceIoControl(hNdis, dwCommand, pInBuffer, cbInBuffer,pOutBuffer, (pcbOutBuffer ? *pcbOutBuffer : 0),pcbOutBuffer, NULL);<BR/> ::CloseHandle(hNdis);<BR/> }<BR/> return fResult;<BR/>}Vaisakh P Shttps://www.blogger.com/profile/02782445552012217777noreply@blogger.comtag:blogger.com,1999:blog-1053373784078711683.post-41613823999653607822008-11-15T21:44:00.000-08:002008-11-15T21:44:00.000-08:00sorry for the delay in reply dude... been busy in ...sorry for the delay in reply dude... been busy in last couple of weeks :)Vaisakh P Shttps://www.blogger.com/profile/02782445552012217777noreply@blogger.comtag:blogger.com,1999:blog-1053373784078711683.post-39712381581329607032008-11-15T21:42:00.000-08:002008-11-15T21:42:00.000-08:00DoNdisIOControl is just a wrapper function i prov...DoNdisIOControl is just a wrapper function i provided to do the ioctl calls... i can send u the fulll source code if u want ;)Vaisakh P Shttps://www.blogger.com/profile/02782445552012217777noreply@blogger.comtag:blogger.com,1999:blog-1053373784078711683.post-75647806143072110012008-11-04T03:55:00.000-08:002008-11-04T03:55:00.000-08:00very useful article. thanks .I'm using Evc++ . Whe...very useful article. thanks .<BR/><BR/>I'm using Evc++ . When try to compile this method, i get an error like below ;<BR/><BR/><B>error C2065: DoNdisIOControl : undeclared identifier</B><BR/><BR/>my include class like below;<BR/><BR/>#include "Atlbase.h"<BR/>#include "Winreg.h"<BR/><BR/>#include "winioctl.h"<BR/>#include "ntddndis.h"<BR/><BR/>#include "windows.h"<BR/>#include "tchar.h"<BR/>#include "stdio.h"<BR/>#include "stdarg.h"<BR/>#include "netcon.h"<BR/>#include "iphlpapi.h"<BR/>#include "pm.h"<BR/>#include "winsock.h"<BR/>#include "ndispwr.h"<BR/>#include "string.h"<BR/><BR/>have any ideaKültür Mantarıhttps://www.blogger.com/profile/05670869586678076064noreply@blogger.com