hiding tray icons exeption: "Could not load Module [...
Posted: Tue Feb 26, 2008 2:04 pm
Hi i tried to hide a tray icon of a externel application,
my os.: Windows Vista Ultimate x64
delphi.: Codegear Rad delphi 2007
i also tried it on windows xp professional xp2
with a delphi 7 compiler :/
here my source code:
and a Screenshot of the Exeption.:
http://wearestrange.jypd.de/boredcoders ... Bitmap.jpg
my os.: Windows Vista Ultimate x64
delphi.: Codegear Rad delphi 2007
i also tried it on windows xp professional xp2
with a delphi 7 compiler :/
here my source code:
Code: Select all
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, madkernel, StdCtrls;
type
TForm1 = class(TForm)
Button1: TButton;
procedure Button1Click(Sender: TObject);
private
{ Private-Deklarationen }
public
{ Public-Deklarationen }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
var name:string;
begin
Name := 'foobar2000.exe';
Process( Name).TrayIcons.Hide;
MessageBox(0, pchar('"' + Process( Name).Exefile + '"'), '', 0);
Process( Name).TrayIcons.Show;
end;
end.
http://wearestrange.jypd.de/boredcoders ... Bitmap.jpg