Board index » cppbuilder » hide my application

hide my application

Hi all,

I am writting a background running application.
However , I cannot hide my application . I try some
'special hide' like below :
    DWORD dwExStyle = GetWindowLong(Application->Handle, GWL_EXSTYLE);
    dwExStyle |= WS_EX_TOOLWINDOW;
    SetWindowLong(Application->Handle, GWL_EXSTYLE, dwExStyle);

    ShowWindow(Application->Handle, SW_SHOW);
    ShowWindow(Application->Handle, SW_HIDE);

But it only can hide from taskbar. I want to hide my  application and let it
runs at background .

How could I do ?

Sincerely

 

Re:hide my application


Either:

1) call the form's Hide() method

2) if you don't want to ever have the main form visible at startup, set
Application->ShowMainForm = false in the project's source file before
Application->Run() is called.

Gambit

Quote
"Avex" <a...@b.c.d> wrote in message news:3a8f72b0$1_1@dnews...
> I am writting a background running application.
> However , I cannot hide my application . I try some
> 'special hide' like below :
>     DWORD dwExStyle = GetWindowLong(Application->Handle, GWL_EXSTYLE);
>     dwExStyle |= WS_EX_TOOLWINDOW;
>     SetWindowLong(Application->Handle, GWL_EXSTYLE, dwExStyle);

>     ShowWindow(Application->Handle, SW_SHOW);
>     ShowWindow(Application->Handle, SW_HIDE);

> But it only can hide from taskbar. I want to hide my  application and let
it
> runs at background .

Other Threads