Disclaimer

This is a personal weblog. The opinions expressed here represent my own and not those of my employer. All code samples are provided “AS IS” without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and/or fitness for a particular purpose.

0

Why does the NdrClientCall2() API call takes more then 4-5 milliseconds to complete?

Question: Why does the NdrClientCall2() API call takes more then 4-5 milliseconds to complete in my application? In rare cases I even see hundreds of milliseconds (57 millisecond at one time) just for the NdrClientCall2() API call to complete. In my application no server side processing is involved. My client and server both are running on…

0

Why does the TCP three way handshake never tag with DSCP value on Windows XP and Server 2003?

Question: We are trying to introduce QoS into our VOIP services. While working on this we have observed that TCP three way handshake never tag with DSCP value. We have reproduced the issue both in Windows XP and Windows Server 2003 operating systems. My question is why TCP three way handshake never tag with DSCP…

0

Why does regedit.exe (or any other Microsoft program) crash when I try to create a remote thread into it using the CreateRemoteThread API?

Question: On Windows XP, I am starting regedit.exe in suspended mode and forcing it to call the LoadLibrary() API to load an external DLL by using the CreateRemoteThread API. After loading the DLL, when I try to resume the suspended thread, the application terminates. Is this a known issue? Answer: Creating a remote thread into…

0

How to check SLP 1.0 values from the BIOS using Win32 API?

Question: Is there any API available to check SLP 1.0 values from the BIOS? Answer: Yes, you can use EnumSystemFirmwareTables API for that. EnumSystemFirmwareTables API enumerates all system firmware tables of the specified type. It supports 3 types of firmware table provider. The ACPI firmware table provider The raw firmware table provider and The raw…

0

How to programmatically set WMP the default player of Windows Vista and Windows 7?

Here is the API that one can use to set the default playback application of Windows Vista and Windows 7: IApplicationAssociationRegistration::SetAppAsDefaultAll Method http://msdn.microsoft.com/en-us/library/bb776338(v=VS.85).aspx This method takes only one parameter – a pointer to a null-terminated Unicode string that specifies the registered name of the application. In this case it will be “Windows Media Player”.

0

Does WIA Automation Layer 2.0 support duplex scan?

WIA Automation Layer 2.0 doesn’t support duplex scan. This is by design. WIA Automation Layer 2.0 is based on WIA 1.0. The issue is not related to WIA 1.0, but the way automation layer has been designed to use WIA 1.0 for functionalities. Use native WIA 2.0 or WIA 1.0 (preferably 2.0, if the target…

0