![]() |
Application.MainForm.Show & TForm1.Minimize
Hi,
ich möchte meine Anwendung ins Systemtray befördern, sobald man auf "Minimieren" klickt. Per Rechtsklick auf das Trayicon zeigt sich das Programm wieder. Das Problem ist, dass das Programm dann aber eigentlich noch den minimierten Status hat, obwohl es gezeigt wird. Deshalb reagiert dann der Minimiere-Button nicht mehr, solange bis ich mit Rechtsklick->Wiederherstellen das Programm wieder hergestellt habe. Weiß jemand, wie ich das Problem lösen kann? Danke schon mal für Hilfe im Vorraus. MfG: sk0r |
Re: Application.MainForm.Show & TForm1.Minimize
Hallo,
Wie "minimierst" du ins TNA? |
Re: Application.MainForm.Show & TForm1.Minimize
Hi,
Delphi-Quellcode:
MfG: sk0r
procedure TForm1.AppMinimize(Sender: TObject);
begin TrayIcon.cbSize := sizeof(TrayIcon); TrayIcon.Wnd := Handle; TrayIcon.uID := 0; TrayIcon.uFlags := NIF_ICON or NIF_MESSAGE or NIF_TIP; TrayIcon.uCallbackMessage := WM_TRAYICON; TrayIcon.hIcon := Application.Icon.Handle; TrayIcon.szTip := 'Name'; Shell_NotifyIcon(NIM_ADD, @TrayIcon); Application.MainForm.Hide; end; |
Alle Zeitangaben in WEZ +1. Es ist jetzt 10:37 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024 by Thomas Breitkreuz