Re: Win32Lib; Timed events

new topic     » goto parent     » topic index » view thread      » older message » newer message

Bernie Ryan wrote:
> 
> ZNorQ wrote:
> > 
> > CChris wrote:
> > > 
> > > I said "any control will do". 0 is not an actual control id, not even a
> > > valid
> > > handle for Windows. It is a special value which is treated, somewhat
> > > consistently,
> > > as if refeerring to the desktop window. But it actually doesn't.
> > > 
> > > CChris
> > 
> > Ah, ok. But how would i go about then when I'm creating a program that
> > doesn't
> > pop-up a window. I know I can use WinMain(0, Normal), but how do I use the
> > timer
> > in this case?
> > 
> > Purpose of the code; Run in the background and run various code in
> > intervals.
> > 
> > Kenneth/ZNorQ
> 
> You can use HWND GetDesktopWindow(VOID) to get a handle to desktop
> 
> window which is in most cases always available and use that with your timer.
> 
> Bernie
> 
> My files in archive:
> WMOTOR, XMOTOR, W32ENGIN, MIXEDLIB, EU_ENGIN, WIN32ERU, WIN32API 
> 
> Can be downloaded here:
> <a
> href="http://www.rapideuphoria.com/cgi-bin/asearch.exu?dos=on&win=on&lnx=on&gen=on&keywords=bernie+ryan">http://www.rapideuphoria.com/cgi-bin/asearch.exu?dos=on&win=on&lnx=on&gen=on&keywords=bernie+ryan</a>

Ok, but I'm not really after the desktop handle, unless I can use that for
attaching my timer to it...? As you've problably read earlier in my posts, I
create a dummy window that I link my timer to, but I never use the window, by
starting with WinMain(0, Normal). Don't know if this is the best way to do it,
but it seems to work for me. :)

ZNorQ

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu