How to verify an exe/dll/sys is original from Microsoft?
I need some easy API to verify that a PE file is valid & Microsoft signed just like SignTool. Where should I start? Could this be done with CAPICOM? ...
I need some easy API to verify that a PE file is valid & Microsoft signed just like SignTool. Where should I start? Could this be done with CAPICOM? ...
Hello. I'm looking for small utility to run on windows mobile phone and trace all windows messages it receive. Not message codes, but names if it could figure them out. I could probably write on for my own, but don't know where I could get a dictionary of WM. Parsing .H files perspective drives me mad. ...
The Win32 GetTimeZoneInformation function returns your systems local time zone as set up in the control panel. How do I get another specific time zone? Is there a call that does this? Tony ...
Using the Win32 API (in C, but that's inconsequential) how can I tell if a given window (identified by HWND) has focus? I'm hooking an application watching for an event, and when that event occurs I want to check if the application already has focus. If it doesn't, I want to flash the window until they give focus to it. Alternately, doe...
Hi all, My company, like everyone else's, requires password resets from time to time. This is all good and well for security's sake, but I'd like to explore the challenge of resetting it through a script (notably because we can't use our previous 25 passwords; Perl is much quicker about cycling through a list two-dozen deep than my fing...
Hi there! During some research in the .net 3.5 symbols I've found a preprocessor directive #if WIN95_SUPPORT //... #endif This looks really strange to me! It is located in line 13861 in System.Windows.Forms.Control's Control.cs in method void WndProc(ref Message m)! Does any of you know anything about that? ...
I remember using a program, some years back, that allowed me to fine-tune my monitor's settings with custom gamma ramps and other adjustments. It had the ability to create different screen-settings profiles for different uses, and setup global hotkey shortcuts to activate them without switching out of the program you're in. My question...
I'm not sure what they call the fake shortcuts you often see in Windows now. A good example would be the link to any of the Office 2007 programs. You can tell one of these from a regular shortcut because the Target is grayed out and is not a real path. Can you access these through a .NET API? Like ask for the target? or get any of the in...
I have a self upgrade process implemented where my main application exe launches an updater exe passing a handle to itself on the command line. The application exe then calls ExitProcess to exit, and the updater calls WaitForSingleObject on the passed in handle to wait for the application exe to terminate. The WaitForSingleObject does w...
I'm using the VerQueryValue to retrieve strings from a DLL's VersionInfo. All works fine, except that the FileVersion displayed by Explorer (right-click on file, Properties, Details, "File Version") doesn't match the string I get from the VerQueryValue. All my other calls to VerQueryValue are working fine, but FileVersion seems to retr...
I have a chart (in bitmap format) that I'm trying to render to a printer using StretchBlt. When drawing to the screen, StretchBlt works fine. When drawing to a CutePDF printer, it returns 0, sets the last error to ERROR_INVALID_HANDLE, and works anyway. When drawing to a PDF995 printer or a physical HP printer, it returns 0, sets the ...
Is there a way to get this functionality under mod_perl2? And can it be triggered via web requests as opposed to the command line? Or do I need to fake whatever $ENV variables and query strings and cookies that my script requires and use the command line somehow? Google and CPAN searches all seem to point to things that either don't e...
Hello, I am trying to figure out how can I send a running application do a new Windows desktop created with CreateDesktop. I can create a new Desktop, and then launch an application in it, bug I can't find the way to do it with a running application. All functions related to Desktop management (i.ec, SetThreadDesktop) always apply only...
I'm writing a Win32 service in C++. I have a custom Assert macro that calls DebugBreak() (among other things). When I'm running my service under Vista, the service crashes when reaching the DebugBreak() call (an int 3 assembler opcode), showing the vista crash dialog. The error code is 80000003 (hardcoded breakpoint). Normally I'm expec...
Hello, Is it a good idea to use GetGuiResources(GetCurrentProcess(),GR_GDIOBJECTS) at the start of winmain, and before the last return to detect GDI leaks or more specifically objects I forgot to release ?Also I'm currently wondering why the first call in my progam returns 4 when there's no window yet. ...
Is there an equivalent event to LBN_SELCHANGE but for a listview? ...
Is there any way to take advantage of the file creation flags in the Win32 API such as FILE_FLAG_DELETE_ON_CLOSE or FILE_FLAG_WRITE_THROUGH as described here http://msdn.microsoft.com/en-us/library/aa363858(VS.85).aspx , but then force that handle into a std::ofstream? The interface to ofstream is obviously platform independent; I'd lik...
I'm wondering how to dock / snap a window to the side of the screen in Windows, preferably with straight Win32 API. The effect I'm looking for is like the task bar -- a window that has a reserved space on screen, so that maximizing another window makes that window take up the rest of the screen, but leaves my window in place and visible....
I'm using timer queues in my application, and pass a pointer to one of my own C++ Timer objects as the 'parameter' to the callback (in CreateTimerQueueTimer). I then call a virtual method on the object in the callback. The destructor of the Timer object will make sure to cancel the timer using DeleteTimerQueueTimer(). static void callb...
In Visual C++ , when I build a dll , the output files are .dll and .lib. Is the name of the dll built into the .lib file . The reasson I ask this question is : When I built my exe by importing this dll and run the exe , the exe tries to locate the dll to load it in the process address space . As we just specify the library name (.li...