winapi

How to play video?

Hi, I'm not c++ programmer so I have problem. Simple problem, I think. I need play movie, can be only e.g. .avi (I can convert). Static width, static height, no button, no loop. I will write in PHP something like exec('window.exe movie23.avi'); And appears window, play video, window close. I rely code or good links. Best regards ...

What is the reason for an unhandled win32 exception in an installer program?

I got the following message: An unhandled win32 exception occurred in numpy-1.5.0-sse3.exe [3324]. The exception occurred in the Numpy installer for Python 2.7---I have the latter on the machine. When I clicked "Yes" for using the selected debugger, I got the following message: The Application Data folder for Visual Studio could not ...

Direct Show graph - how to get the current fps?

Hello I have an instance of IFilterGraph - my own graph with video filters (source, transofrm and renderer). How can I obtain the current fps (video frame rate) of running graph? Regards Dominik ...

Getting current Windows system input language and notifications when the language changes.

I am writing on screen keyboard application. The keyboard is running in separate process and the application window is topmost and does not get focus. When I switch between applications, the language is changed. How can I get the current selected language on toolbar and how can I be notified when it is changed? InputLanguageManager and ...

How do you capture Console I/O (not stdio) in Windows?

Why would I want to? Because I'm writing my own cmd.exe replacement! I can CreateProcess and pass in handles to pipes for stdin and stdout and stderr, and I see how I can AllocConsole, FreeConsole, and AttachConsole, but how do I tell child programs that my program is the console? More detail for clarification: I've got a window that ...

win32: moving mouse with SetCursorPos vs. mouse_event

Is there any difference between moving the mouse in windows using the following two techniques? win32api.SetCursorPos((x,y)) vs: nx = x*65535/win32api.GetSystemMetrics(0) ny = y*65535/win32api.GetSystemMetrics(1) win32api.mouse_event(win32con.MOUSEEVENTF_ABSOLUTE|win32con.MOUSEEVENTF_MOVE,nx,ny) Does anything happen differently in ...

win32: simulate a click without simulating mouse movement?

I'm trying to simulate a mouse click on a window. I currently have success doing this as follows (I'm using Python, but it should apply to general win32): win32api.SetCursorPos((x,y)) win32api.mouse_event(win32con.MOUSEEVENTF_LEFTDOWN,0,0) win32api.mouse_event(win32con.MOUSEEVENTF_LEFTUP,0,0) This works fine. However, if the click hap...

Changing a process name in runtime.

For A.EXE PE file, if the program runs as test mode, I would like to change the process name to "A_TEST.exe". And if the program runs as safe mode, I want to change to "A_SAFE.exe" The file name must be same(A.EXE). Is it possible? ...

Emulate mouse select messages between windows

Hi, I've got two windows in the same process. Window 1 contains some text. Window 2 contains a bitmap of the contents of window 1. Whenever I click (WM_LBUTTONDOWN ) or move (WM_MOUSEMOVE) the cursor in window 2, i pass the message into window 1 by posting the message to window 1's message queue. I now want to emulate more complex...

Why doesn't c++ have a mouse over message

really why it doesn't. it can help alot of programmers. ...

How can a 64-bit process have a 32-bit view of file system and registry?

For backwards compatibility, my 64 process needs to see the the 32-bit view of the file system and registry. I know how to make a 32-bit process see a 64-bit view of the file system and registry (using Wow64DisableWow64FsRedirection and Wow64RevertWow64FsRedirection) But how do I make a 64 bit process have a 32 bit view of the file sys...

Existing windows application to intel appup

Intel has provided one SDK for developing and submitting applications to intel appup. It is mentioned that C/C++ Win32 applications are supported in it. Is there any way to submit the existing C# Win32 application to appup. ...

Closing a MessageBox automatically

I have a third party encryption library, which may create a MessageBox if key creation fails. The failure can be caused by bad random number generation or other rarities, and in most cases, trying again will result in success. My code will attempt key creation up to three times before deciding it failed. Now, the issue is that the progr...

Play avi using animation control

Hi, I,m not c++ programmer on a daily basis, so I need help. I 'wrote' this. It's new project 'Windows Application' in DevC++. I add this #include <Commctrl.h> //... HWND film; //... film = Animate_Create(hwnd, 10, WS_CHILD | WS_VISIBLE | ACS_AUTOPLAY, hThisInstance); Animate_OpenEx(film, hThisInstance, "a.avi"); Animate_Play(film, 0...

How to open a Win32 dialogbox from inside a VST plug-in?

How to open a Win32 dialogbox from inside a VST plug-in? Thanks for any help. ...

Class method as winAPI callback

Is it feasible to set the winAPI message callback function as a method of a class. If so, how would this be best implemented? I wonder if it is even possible. Sorry for the short question, hopefully you will be able to provide useful responses. Thanks in advance :). ...

How to send unicode keys with c++ (keybd_event)

My friend is learning Norwegian and i want to make a global hot key program which sends keys such as æ ø å My problem is that keybd_event function wont allow me to send those keys, i seem to be restricted to the virtual key codes is there another function that i could use or some trick to sending them? ...

A link problem with Windows 7 shell functions

Hello, I'm trying to enumerate files through the Windos 7 library API, e.g. with SHLoadLibraryFromKnownFolder I'm using a C++ win32 console application and getting link errors, e.g., Error LNK2019: unresolved external symbol __imp__DSA_DestroyCallback@12 referenced in function "void __cdecl DSA_DestroyCallback(struct _DSA *,int (__stdc...

Calling RegOpenCurrentUser in VC++ 6

I'm working on a Visual C++ 8 project on WinXP but unfortunately I have only Visual C++ 6.0 available. When compiling it,an error is raised: "error C2065: 'RegOpenCurrentUser' : undeclared identifier". Since RegOpenCurrentUser has been introduced as late as Windows 2000,it's not included in VC6 header files.I try to declare it myself an...

Why would InternetOpenURL report error 2 (the system cannot find the file specified)?

Hi, The internet access code in our product works perfectly for 99.99% of people. However, for a few of them, it just doesn't work at all. We've been adding some trace code to try and figure out what the problem is, and it it turns out that InternetOpenURL is reporting error 2 - "The system cannot find the file specified" - from this fu...