2,736 questions with Windows API - Win32 tags

Sort by: Updated
0 answers

How to get the path of the selected file in the current tab of Windows Explorer?

The end goal: • Open Explorer (multiple tabs) in win11. • Select a file • Press the space bar to get the selected file path in your own program

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-28T11:29:23.1966667+00:00
john snow 0 Reputation points
0 answers

why uiautomation findFirst is slow and can i correct it?

Hello, I want to find some ui elements in windows apps but when i find it using uiautomation findAll or findFirst it slows down programs. I undertand that there are many elements in ui and it requires going throug many elements but for example in…

Windows
Windows
A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.
5,816 questions
Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-01-25T14:19:43.4133333+00:00
Артур Абубакиров 0 Reputation points
commented 2025-02-28T05:40:15.29+00:00
Артур Абубакиров 0 Reputation points
5 answers

WSUSSCN2.cab file for Windows 11

I have been using a the wsusscn2.cab file and WUA in a script for years to determine the latest non-superseded applicable UpdatesIDs so that I can download them and bring them to my offline networks. Now that we are moving to Windows 11 it seems to me…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
Windows 10 Security
Windows 10 Security
Windows 10: A Microsoft operating system that runs on personal computers and tablets.Security: The precautions taken to guard against crime, attack, sabotage, espionage, or another threat.
3,008 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
10,877 questions
asked 2024-06-13T15:51:07.07+00:00
ArmoredEmu01 5 Reputation points
commented 2025-02-26T18:40:07.71+00:00
ArmoredEmu01 5 Reputation points
0 answers

Speech Recognition customize engine question on Windows about sapi

Hi MSFT member, On windows, when developing a Speech recognition app, there are about three solution APIs: Windows.Media.SpeechRecognition System.Speech Programming Guide for .NET Framework Microsoft Speech API (SAPI) Since We want to use local…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-25T12:29:16.58+00:00
clark-zh 40 Reputation points
commented 2025-02-26T03:38:00.27+00:00
Jeanine Zhang-MSFT 10,856 Reputation points Microsoft Vendor
0 answers

Why does EnumDisplayMonitors Still Return just Disconnected Monitor

I'm working om win32 Desktop application in CPP and I'm checking what happens if I try to fetch Display info with EnumDisplayMonitors when All displays are disconnected! Surprisingly it is giving display info of previously connected Display. Why is this…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-11T06:48:09.9366667+00:00
Harshithraj1871 1,621 Reputation points
commented 2025-02-25T05:47:53.6766667+00:00
Harshithraj1871 1,621 Reputation points
1 answer

Why SetWindowCompositionAttribute makes text also transparent

When I called SetWindowCompositionAttribute to make the main window blurred, text of controls on it also became transparent and thus hard to read. I want to keep the text pure black without transparency while the main window is blurred and transparent.…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-03T03:24:51.68+00:00
szx0427 101 Reputation points
edited the question 2025-02-24T08:06:12.22+00:00
Jack J Jun 24,881 Reputation points Microsoft Vendor
1 answer

How to make a RichEdit control resizable in the up and down directions?

// RichEditReSizeable_cpp_win32.cpp : Defines the entry point for the application. // #include "framework.h" #include "RichEditReSizeable_cpp_win32.h" #define MAX_LOADSTRING 100 #ifndef MSFTEDIT_CLASS #define MSFTEDIT_CLASS…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-02T01:29:39.93+00:00
Cristoforo Montanari 0 Reputation points
edited a comment 2025-02-21T06:18:05.01+00:00
Roy Li - MSFT 34,096 Reputation points Microsoft Vendor
0 answers

DirectComposition click through in transparent areas

I have an application with DirectComposition and Direct2D that I do have a window bigger than the drawings to handle somethings like shadows underneath the rectangles. The issue that I'm having is in the transparent areas, the click-through is not…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-01-31T22:57:11.4266667+00:00
Vitor Hugo Gomes 0 Reputation points
edited a comment 2025-02-21T06:17:48.8033333+00:00
Roy Li - MSFT 34,096 Reputation points Microsoft Vendor
1 answer

In C++, are global objects guaranteed to exist throughout the execution of a SetConsoleCtrlHandler() callback function?

In C++, are global objects guaranteed to exist throughout the execution of a SetConsoleCtrlHandler() callback function? I'm wondering what would happen if both regular program execution (and the eventual destruction of global variables) and the…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,865 questions
asked 2025-02-05T01:22:18.9666667+00:00
Geoff Hale 0 Reputation points
edited a comment 2025-02-21T06:17:15.0633333+00:00
Roy Li - MSFT 34,096 Reputation points Microsoft Vendor
2 answers

Failed to disable Peek Preview in Windows 11

Hi, everyone! To implement some custom fetatures I need to disable peek preview for the window. So I call DwmSetWindowAttribute with DWMWA_DISALLOW_PEEK set to True to disallow peek preview. It works well in Win7 and Win10 but in my newest…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
10,877 questions
asked 2022-07-21T02:13:19.12+00:00
trance 11 Reputation points
commented 2025-02-21T04:41:53.3766667+00:00
Hasaranga 0 Reputation points
4 answers

IUpdate2::CopyToCache method Windows 11

It seems that this method no longer works on Windows 11: https://learn.microsoft.com/en-us/windows/win32/api/wuapi/nf-wuapi-iupdate2-copytocache Interface not registered Do you have an idea?

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
10,877 questions
asked 2024-12-12T12:09:00.7133333+00:00
Simon Fonteneau 75 Reputation points
answered 2025-02-20T08:05:46.9866667+00:00
Friese, Manuela 0 Reputation points
2 answers One of the answers was accepted by the question author.

Why does IPsecSaContextSetSpi0 from the WFP API seem to only accept even SPI values?

When creating an IPsec SA using the WFP API, IpsecSaContextSetSpi0() doesn't seem to accept an odd SPI value. Why is this the case? RFC 4303 Section 2.1 and RFC 4302 Section 2.4 talk about valid SPI values for an IPsec SA. It makes no mention of odd…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-13T19:39:45.3633333+00:00
Nathan 20 Reputation points
edited a comment 2025-02-19T19:03:18.7333333+00:00
Nathan 20 Reputation points
1 answer

How do I force a python script to run in efficiency mode so the green leaf appears next to its' listing in TaskManager?

Hi all, as the title states, I'm looking to make a python script run in efficiency mode and it has to show the leaf in TaskManager so psutils is out (right?). I'm running cmd as administrator and I've tried using ctypes to throttle the power through…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-08T01:30:45.95+00:00
Matt_the_ok 0 Reputation points
answered 2025-02-19T18:09:15.4566667+00:00
Matt_the_ok 0 Reputation points
2 answers One of the answers was accepted by the question author.

CComboBoxEx in dark mode (with Dropdown style) in MFC

I am trying to implement a dark mode for my application, by using DarkMode_Explorer / DarkMode_CFD etc. I have handled OnCtlColor and set the theme using SetWindowTheme. If my CComboBoxEx is a DropList then it renderings properly. But when I set it to…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,865 questions
asked 2025-02-14T18:32:24.68+00:00
ChuckieAJ 261 Reputation points
accepted 2025-02-19T14:36:30.57+00:00
ChuckieAJ 261 Reputation points
0 answers

How to apply ROPs (Raster Operation) when drawing with GDI+ and do we need to use ROPs with GDI+?

I am doing drawing image to EMF file using GDI+ however I don't see any function of GDI+ related to ROPs. I understand that GDI+ is designed with object oriented thinking and supports high quality graphics. So do we need ROPs when using GDI+?

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,865 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
10,877 questions
asked 2025-02-07T02:22:18.55+00:00
lam nguyen 0 Reputation points
commented 2025-02-19T06:20:05.1233333+00:00
Roy Li - MSFT 34,096 Reputation points Microsoft Vendor
2 answers One of the answers was accepted by the question author.

ndfapi.dll's NdfRunDllDiagnoseWithAnswerFile and NetworkDiagnosticsSharing API call Description

Good Day! I have been searching online regarding the API calls NdfRunDllDiagnoseWithAnswerFile and NetworkDiagnosticsSharing but the results were being pointed to **NdfDiagnoseIncident function (ndfapi.h) **which i am not sure if this is the updated…

Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
13,729 questions
Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
Windows Network
Windows Network
Windows: A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.Network: A group of devices that communicate either wirelessly or via a physical connection.
835 questions
asked 2025-02-17T15:56:41.9733333+00:00
Cre Ate 20 Reputation points
commented 2025-02-18T13:19:24.6666667+00:00
Cre Ate 20 Reputation points
3 answers

Does win32 PostMessage and GetMessage use release acquire fencing?

I've been looking ALL over for this information explicitly, but I can not find anything documented. Does PostMessage and GetMessage internally implement or behave like they implement atomic release acquire fencing? Specifically, does PostMessage release…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-12T04:04:12.5433333+00:00
Jim Bean 0 Reputation points
commented 2025-02-14T22:52:59.6166667+00:00
Darran Rowe 1,426 Reputation points
1 answer

Issue with Win32 API Loading of PE Resources Containing Lowercase Letters

Issue description I am creating an abstraction layer over portable executable (PE) resources, and am trying to identify invalid inputs that should be rejected. Through testing I got the impression that certain non-ASCII lower case letters in resource…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2025-02-06T22:30:46.7466667+00:00
MauriceKayser-8381 0 Reputation points
commented 2025-02-12T03:26:15.26+00:00
Jeanine Zhang-MSFT 10,856 Reputation points Microsoft Vendor
1 answer One of the answers was accepted by the question author.

CMFCVisualManager memory leak, still there?

I see that there was a post about this in 2017 (4 years ago), but I'm wondering if it was a bug of of the solution was the correct way of handling it. I'm using VS2019. It looks like when you use a control like CMFCEditBrowseCtrl it can cause a memory…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
asked 2021-11-05T17:39:58.913+00:00
Owen Ransen 546 Reputation points
commented 2025-02-11T22:33:25.2066667+00:00
ChuckieAJ 261 Reputation points
4 answers One of the answers was accepted by the question author.

Unable to set my CStatusBar background colour

I am surprised that I can't do this because the File Explorer in Windows 11 has a dark statusbar. So initially I tried: SetWindowTheme(m_wndStatusBar.GetSafeHWnd(), L"DarkMode_Explorer", nullptr); And it did nothing. I then tried: // Set dark…

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
2,736 questions
C++
C++
A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,865 questions
asked 2025-02-03T11:30:25.02+00:00
ChuckieAJ 261 Reputation points
edited the question 2025-02-11T02:58:35.7333333+00:00
Roy Li - MSFT 34,096 Reputation points Microsoft Vendor