Board index » delphi » Windows task Bar - Keeping it on top

Windows task Bar - Keeping it on top

Hi All
Sorry if this question has come up regularly before.
My D3 app has an MDI form which is maximised when the application starts.
This however means that the Windows task bar is no longer visible.
Is there a simple API call or other trick to keep the task bar on top, or
which has the effect of changing the dimensions of the maximised D3 form, so
that the task bar is always visible.
I have found the API call to locate the position of the task bar, but that
seems a long winded way of solving the problem, and I would have to also
find a way of resizing my MDI form when ever the task bar was moved by the
user etc.

Many thanks in advance to anyone who can assist

Mike Manning
Melbourne, Australia

 

Re:Windows task Bar - Keeping it on top


If you look at Delphi's main window, it changes it's maximum size, because
maximizing that window will **NOT** cause to maximize window over all the
screen (sorry for bad english...). But I do not know, how to change that.

But, are you sure, that your main (not MDI child) window is maximized, or
you can still maximize it? In window's .create event write

-- begin --
{windowname}.windowstate=wsMaximized;
{By the way, replace "{windowname}" with real name of form!}
--  end  --

If it will not work, try this (form will **NOT** be maximized, sorry!)

-- begin --
{windowname}.windowstate=wsNormal;
{windowname}.height:=screen.height;
{windowname}.width:=screen.width;
--  end  --

, but I am not sure, if it works, because (I think) "screen.width" variable
gives you **SCREEN WIDTH**, not screen without taskbar.

Matija

Quote
Mike Manning <mmann...@werple.net.au> wrote in message

news:AXpF3.18212$1E2.134846@ozemail.com.au...
Quote
> Hi All
> Sorry if this question has come up regularly before.
> My D3 app has an MDI form which is maximised when the application starts.
> This however means that the Windows task bar is no longer visible.
> Is there a simple API call or other trick to keep the task bar on top, or
> which has the effect of changing the dimensions of the maximised D3 form,
so
> that the task bar is always visible.
> I have found the API call to locate the position of the task bar, but that
> seems a long winded way of solving the problem, and I would have to also
> find a way of resizing my MDI form when ever the task bar was moved by the
> user etc.

> Many thanks in advance to anyone who can assist

> Mike Manning
> Melbourne, Australia

Other Threads