Preventing the appearance of the main form when showing another form

I try to bring my secondary form to Foreground, but when I do

MyForm.Show; // It may be hidden, therefore show it first
SetForegroundWindow(MyForm.Handle);

my basic form appears. The only way to prevent this is to do it MainForm.Hide;, but I must avoid it.

The idea is for my secondary form to appear on top of another application, without my main form to do this.

+3
source share
2 answers

If you decide to create another application for this function, you can also consider the following tradeoff: minimize MainForm in the taskbar (rather than hide it) to prevent it from appearing when another form is activated.

, . , , , , . , MainForm , , MainForm, .

, : ( ) , . , , , , / VCL.

+2

fsAlwaysOnTop.

0

All Articles