NVMe Sanitize call returns unexpected error 0x13D
Hi, I'm trying to send NVME Sanitize/BlockErase command to NVMe disk which supports that. This shall be available on regular Win11 OS and I'm running 10.0.22000.1098 (10.0.22000.1042 StorNvm driver). I'm receiving absurd last error after…
how to use windows-rs com function CLSIDFromProgID.
Hello, everyone. I am now using windows-rs to migrate previous vb programs. The vb program references a library class. I checked this class through ole/com and found it in Type Libraies, and in HKEY_CLASSES_ROOT in the registry editor, it appears in…
Cannot change Windows 10/11 touch keyboard to Traditional Chinese phonetic layout
I'm an author of a Traditional Chinese Input Method. My IME works very well before Windows 10 Version 1703, but the screen keyboard always shows English layout instead of Chinese Phonetic (Bopomofo) layout after Windows 10 Version 1709. The steps to…
How to read and output the NPU utilization
Hi All How to use the following MS learning to read and output the NPU utilization. Thank you. https://learn.microsoft.com/en-us/windows/win32/api/activitycoordinatortypes/ne-activitycoordinatortypes-activity_coordinator_resource
WIFI DIrect API pair always failed
Hi Everyone, My app need use WIFI Direct feature, so I refer to a Microsoft sample Code (WiFiDirectLegacyAPDemo). For some reason, I can't use legacy mode of WIFI Direct, so I need call customer pair when got a connection request, but it always get a…
IOCTL_STORAGE_FIRMWARE_DOWNLOAD returns ERROR_INVALID_FUNCTION on eMMC laptop
I am developing software for performing firmware updates on laptops with eMMC storage. However, when I issue IOCTL_STORAGE_FIRMWARE_DOWNLOAD, I receive an ERROR_INVALID_FUNCTION. I have also tried using the Intel eMMC firmware update tool, but it fails…
How to programatically get NPU utilization using C/C++/C#
如果一台PC有NPU,那么在Windows 11任务管理器中,“性能”页面就会显示NPU的信息(包括使用率),一般来说,这个页面显示的信息从“性能计数器(PDH)”中获取,但是我并没有找到对应的计数器。有谁知道这个NPU使用率从哪儿获取吗? If a PC has an NPU, then in the Windows 11 Task Manager, the "Performance" page will display the information of the NPU…
NCryptSignHash returns NTE_INVALID_PARAMETER when signing a SHA512 hash
Hello, I've been updating a program to use CNG but have run into a problem where NCryptSignHash returns NTE_INVALID_PARAMETER when I ask it to sign a SHA512 hash. If I change the hashing algorithm to MD5, SHA1, or SHA256 then the function succeeds fine.…
GetWindowPlacement() different values for windows in the exact same location
Why does GetWindowPlacement() give different coordinates for two applications that are positioned in the exact same location. So I opened three different windows of Chrome, and placed them on the exact location all three. One on top of the other. In…
Apply changes made in registry regarding window metrics
I want to set specific values for: Computer\HKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics Is there a way to apply registry changes without the need of logging off and on? Perhaps some service needs restarting? I've tried to restart explorer.exe…
Problem with handling tab key (focusing controls) in a window created by a dll
Hello, I'm developing virtual musical instrument software which can be used as a plugin in Digital Audio Workstations (DAW). The software is based on Steinberg's VST3 SDK and it is written in C++ in Visual Studio 2022. VST3 plugins are DLLs. After being…
Supplied buffer size is incorrect C#?
Alright, hopefully this is my last question on this topic. Currently, I'm having trouble with a program that reads HID input from Joy-Cons to see their button input. When I try to run my program, I get the error code 1784 from ReadFile for a invalid user…
C# HID Input Report Problem.
Currently I'm having a problem with getting input reports from a HID device. What's happening is that I'm getting the device path of the device, but CreateFileW doesn't recognize it as a valid device path. Here's my platform invokes and main function…
Where can I find sendmsg and recvmsg refered to in https://learn.microsoft.com/en-us/windows/win32/winsock/winsock-ecn
See page https://learn.microsoft.com/en-us/windows/win32/winsock/winsock-ecn. I tried to find sendmsg and recvmsg functions, but couldn't find them. In which header are they defined? Or are these wrapper functions I have to write myself?
IO Completion Ports - error 998
Explain, please, what am I doing wrong? I am trying to make a simple client based on IOCP: But, i always get the gatelasterror error 998 when calling GetQueuedCompletionStatus. I just can't understand - what I'm doing wrong. :(
C# Printing problem with system.Drawing.Printing from #web API
Hello everyone, I have a situation to print PDF document as a batch from Web API. And I have used System.Drawing.Printing Library to print them. I have noticed the ‘Caution’ mentioned on Microsoft site…
why my application freezes when reading a nvenc-h264 encoded video file in Windows 10 but not on windows 11
Hi Everyone, I have the video file with the following details: General Complete name : D:\this_video_causes_error.avi Format : AVI Format/Info : Audio Video Interleave File size : 16.7 MiB Duration : 1 min 0 s Overall bit rate mode : Variable Overall bit…
When using the Win32 GetAppliedGPOList in C, the GPO list pointer is always NULL even when trying multiple GUIDs and even when the API returns success.
In the code below, pGPOList (the GPO list) is always NULL even when the GetAppliedGPOList returns success. I have tried multiple group policy extension GUIDs, but no luck. What am I doing wrong? This also happens when I try GetAppliedGPOList with user…
is there any library to extract user information of microsoft logged account other than win32com?
I tried to deploy a web service to azure portal (linux). However, my app service doesn't work and it stated "ModuleNotFoundError: No module named 'win32com'". I believe that win32com is not compatible for linux and exclusively only for…
Office 365 vs Office 2016 API problems
I have a Delphi application that has been running for years leveraging the Excel APIs (very similar structural calls as in VBA). I have even moved to later versions of Office over the years with no issues. I recently had a user begin running the Delphi…