Re: System Wide Hook to Center Dialog Windows - Help



On 9 Feb 2006 12:25:44 -0800, "soorya" <blackmagicinc@xxxxxxxxx>
wrote:

i need to make system wide hook, to make any dialog/msgbox windows
center.
since i am a vb6 programer, i need c++ dll to do this.
can some one help me where can i get free dll to use with VB6 and a
sample.

There are some free hook dlls (DS_) here.
http://www.mentalis.org/index2.shtml


i tried general system wide CBT Hook dll and fired at HCBT_CREATEWND
but if i use GetwindowRect() and MoveWindow() the dialog window is not
moving at all.

That's most likely a timing issue, iow you're probably moving it too
soon. The app creating the dialog or the default dlg proc itself is
moving the window after it's created. Try hooking WM_INITDIALOG with a
WH_CALLWNDPROC hook instead.


and any one know how to clear last window position in WinXP ?
No idea.


-Tom
MVP - Visual Basic
(please post replies to the newsgroup)
.



Relevant Pages

  • Re: MODULES vs FILES in bib file
    ... Moving the dll from MODULES to FILES in Windows ... I agree with Paul though, ... performance of the driver will have any impact. ...
    (microsoft.public.windowsce.platbuilder)
  • Re: Multiple instances of a single DLL
    ... But moving everything to a common struct ... How can I load a DLL several times in a process? ... Do you have the DLL source code? ... by moving them into a "context" struct which the caller must provide. ...
    (microsoft.public.win32.programmer.kernel)
  • Re: InitializeSecurityContext returns SEC_E_UNSUPPORTED_FUNCTION on XP??
    ... I've got a call of InitializeSecurityContext which works on one machine ... but moving the DLL to another machine ... Tim Ward ...
    (microsoft.public.platformsdk.security)
  • Re: onboard EROM PXE programming in windows
    ... > In my case the expansion ROM base address will be a memory mapped ... ups sorry the free DLL mainly only have IO access and not memory acces:( ... we use some other $$$ dll for memory access. ... but its actually not difficult at all to write the driver yourself if you ...
    (comp.arch.embedded)
  • System Wide Hook to Center Dialog Windows - Help
    ... since i am a vb6 programer, i need c++ dll to do this. ... i tried general system wide CBT Hook dll and fired at HCBT_CREATEWND ... and any one know how to clear last window position in WinXP? ...
    (microsoft.public.vb.winapi)