Questions tagged [winapi]

The Windows API (formerly called the Win32 API) is the core set of application programming interfaces available for the Microsoft Windows operating systems. This tag is for questions about developing native Windows applications using the Windows API.

The Windows API, informally WinAPI, is Microsoft's core set of application programming interfaces (APIs) available in the Microsoft Windows operating systems. It was formerly called the Win32 API; however, the name Windows API more accurately reflects its roots in 16-bit Windows and its support on 64-bit Windows. Almost all Windows programs interact with the Windows API. You can find more help on the Windows API Documentation.

The Windows API (Win32) is primarily focused on the C programming language in that its exposed functions and data structures are described in that language in recent versions of its documentation. However, the API may be used by any programming language compiler or assembler capable of handling the (well defined) low level data structures along with the prescribed calling conventions for calls and callbacks.

42239 questions
10
votes
3 answers

Windows Volume Mixer icon size is too large

In the Windows Volume Mixer, when your application plays sounds, it adds your application's icon and a custom volume slider to adjust volume specific to that application... nice! However, when you use a large-sized icon for your application…
mark
  • 5,269
  • 2
  • 21
  • 34
10
votes
2 answers

Named pipes efficient asynchronous design

The problem: To design an efficient and very fast named-pipes client server framework. Current state: I already have battle proven production tested framework. It is fast, however it uses one thread per one pipe connection and if there are many…
Runner
  • 6,073
  • 26
  • 38
10
votes
1 answer

Why the LogonUser function always return true using the LOGON32_LOGON_NETWORK mode?

I need to use the LogonUser WinApi function on my Server App, but this function always returns true no matter if the user and password match or exists. This only happens when the mode passed to the function is LOGON32_LOGON_NETWORK {$APPTYPE…
Salvador
  • 16,132
  • 33
  • 143
  • 245
10
votes
1 answer

Is there no GetFilePointer(Ex) Windows API function?

I am trying to debug a program that manipulates a file. For example, I set the file-pointer to offset 4 (using a base of 0), but it seems to be starting at offset 5 instead. To try to figure out what is happening, I want to put in a line to print…
Synetech
  • 9,643
  • 9
  • 64
  • 96
10
votes
3 answers

excel access denied with win32 python pywin32

My code is #Opens template for creating final report excel = win32.dynamic.Dispatch('Excel.Application') template = os.path.abspath((folderpath+'\Poop.xlsx')) wb = excel.Workbooks.Open(template) freshws= wb.Sheets("Fresh") #Sheet names must match…
Drfrink
  • 404
  • 1
  • 9
  • 25
10
votes
1 answer

Delphi : how to check if a file exists (path over 255 characters)

I need to make my delphi app able to check if a file copied using Robocopy is there or not when its path exceeds 255 characters. I have tried the usual "If FileExists(MyFile) then ... " but it always returns "false" even if the file is there. I also…
Fab
  • 103
  • 1
  • 4
10
votes
2 answers

How to get the current URL from Chrome 28 from another Windows application?

Up to Chrome V27 you could enumerate Chrome child window controls to get to the edit field and read the string value from there to get the current opened URL. Unfortunately Chrome 28 has switched to the new rendering Engine (Blink) and does not use…
Casady
  • 1,426
  • 3
  • 19
  • 39
10
votes
1 answer

AccessViolationException is thrown using WinAPI in Windows 8 Pro Tablet

I am trying to write an accesibility app for 32bit Windows 8 Pro tablet PC using Magnification API. App can perfectly zoom-in and zoom-out full screen, but when zoomed in, the click events are sent to wrong places of the unmagnified screen, so user…
Alpay
  • 1,350
  • 2
  • 24
  • 56
10
votes
6 answers

Quickest way to implement a C++ Win32 Splash Screen

What's a simple way to implement a c++ Win32 program to... - display an 800x600x24 uncompressed bitmap image - in a window without borders (the only thing visible is the image) - that closes after ten seconds - and doesn't use MFC
BeachRunnerFred
  • 18,070
  • 35
  • 139
  • 238
10
votes
4 answers

How to launch an executable on the end of installation with proper rights?

I'm launching my Windows application this way after the installation completes: !define MUI_FINISHPAGE_RUN_FUNCTION "LaunchApplication" ... Function LaunchApplication ExecShell "" "$INSTDIR\Application.exe" FunctionEnd But this has a strange…
Casady
  • 1,426
  • 3
  • 19
  • 39
10
votes
1 answer

Windows - code to block toast notifications? (Win32/MFC desktop)

Everything I can find on toast notifications is about how to send them or fix problems with sending them. I have a full-screen desktop application where I want to STOP toast from popping up while it runs. So far the only way I've found to do this…
Dave S
  • 1,427
  • 1
  • 16
  • 18
10
votes
2 answers

sz and pwsz prefixes in WinAPI

I'm a little confused now with the hungarian notation prefixes in WinAPI for CHAR strings and WCHAR strings. When we use a CHAR string usually such a prefix is used: CHAR szString[] = "Hello"; We have a zero-terminated string szString so…
spandei
  • 219
  • 3
  • 16
10
votes
1 answer

How to use winapi SetWinEventHook in python?

I want to get the handle of every new Dialog which pops up from a specific application. I understand I should set a hook with SetWinEventHook which is in user32.dll in windows, but I don't know how to do that in python. Would you give me an example…
kissgyorgy
  • 2,947
  • 2
  • 32
  • 54
10
votes
2 answers

Serial communication with minimal delay

I have a computer which is connected with external devices via serial communication (i.e. RS-232/RS-422 of physical or emulated serial ports). They communicate with each other by frequent data exchange (30Hz) but with only small data packet (less…
rnd_nr_gen
  • 2,203
  • 3
  • 36
  • 55
10
votes
3 answers

Edit control capture enter key

I have an edit control HWND hInput = CreateWindowEx(WS_EX_CLIENTEDGE, "EDIT", "", WS_CHILD | WS_VISIBLE | WS_VSCROLL | ES_MULTILINE | ES_AUTOVSCROLL, 0, 0, 100, 100, hwnd, (HMENU)IDC_MAIN_INPUT, GetModuleHandle(NULL), NULL); and a…
Johnny Mnemonic
  • 3,822
  • 5
  • 21
  • 33
1 2 3
99
100