Board index » delphi » Empty button on task bar.

Empty button on task bar.

Hi Group,

This should be an easy one to answer:

I've created an application with just one form with BorderStyle = bsNone and
WindowsState = wsMaximized. When I close the application, there is an empty
button on the task bar.

Two questions:

1) Why?
2) How can I get rid of it?

TIA

- daniel

 

Re:Empty button on task bar.


This is a bug of windows. On your onclose event you can set windowsstate to
fsnormal.

Cheers,
Nicholas Sherlock

Quote
"Daniel Rutten" <n...@junk.com> wrote in message

news:1032732281.401900@cereal.attica.net.nz...
Quote
> Hi Group,

> This should be an easy one to answer:

> I've created an application with just one form with BorderStyle = bsNone
and
> WindowsState = wsMaximized. When I close the application, there is an
empty
> button on the task bar.

> Two questions:

> 1) Why?
> 2) How can I get rid of it?

> TIA

> - daniel

Re:Empty button on task bar.


Quote
> This is a bug of windows. On your onclose event you can set windowsstate
to
> fsnormal.

(I hope this is a typo and you mean wsNormal... fsNormal has to with the
FormState (MDI))

I'm sorry to inform you that your solution does not work on Windows 98 SE...
any other thoughts?

- daniel

Re:Empty button on task bar.


I had this problem as well (Win.98SE, D5E).
The solution that was sent to me, also, was WindowState to wsNormal.
Just to be on the safe side, I also did FormStyle to fsNormal,
and also reduced my form.width and form.height.
It worked for me!!

James

Quote
"Daniel Rutten" <n...@junk.com> wrote in message

news:1032817499.492667@cereal.attica.net.nz...
Quote
> > This is a bug of windows. On your onclose event you can set windowsstate
> to
> > fsnormal.

> (I hope this is a typo and you mean wsNormal... fsNormal has to with the
> FormState (MDI))

> I'm sorry to inform you that your solution does not work on Windows 98
SE...
> any other thoughts?

> - daniel

Re:Empty button on task bar.


Quote
> I had this problem as well (Win.98SE, D5E).
> The solution that was sent to me, also, was WindowState to wsNormal.
> Just to be on the safe side, I also did FormStyle to fsNormal,
> and also reduced my form.width and form.height.
> It worked for me!!

No matter what I do (I've tried setting the BorderStyle, WindowState,
FormStyle, Left, Top, Height and Width properties) I *sometimes* get the
empty button. There is no pattern...

- daniel

Re:Empty button on task bar.


Quote
> It worked for me!!

What worked for me is this:

WindowState := wsNormal and in the FormCreate

  Left := 0;
  Top := 0;
  Width := Screen.Width;
  Height := Screen.Height;

Same effect... no empty button.

- daniel

Re:Empty button on task bar.


Quote
"Daniel Rutten" <n...@junk.com> wrote in message

news:1032828982.825338@cereal.attica.net.nz...

Quote
> > It worked for me!!

> What worked for me is this:

> WindowState := wsNormal and in the FormCreate

>   Left := 0;
>   Top := 0;
>   Width := Screen.Width;
>   Height := Screen.Height;

> Same effect... no empty button.

Eh... that is... the first twenty times, after that... hello... an empty
button again...

- daniel

Re:Empty button on task bar.


Before the application terminates, try to hide it,
so that it disappears from the task bar...

Other Threads