Autor Beitrag
patmann2001
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 201

Windows 7 Prof.
Delphi XE2
BeitragVerfasst: Mi 04.09.02 18:06 
Ich suche eine Möglichkeit
1. Festzustellen ob der Aktive Desktop aktive ist und
2. Ihn ein- oder auszuschalten

cu Patmann
toms
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 1099
Erhaltene Danke: 2



BeitragVerfasst: Mi 04.09.02 18:14 
toms
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 1099
Erhaltene Danke: 2



BeitragVerfasst: Mi 04.09.02 18:55 
Zitat:
2. Ihn ein- oder auszuschalten


Probier's mal mit dieser Funktion:

ausblenden Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
procedure EnableActiveDesktop(bValue: Boolean);
const
  CLSID_ActiveDesktop: TGUID = (D1: $75048700; D2: $EF1F; D3: $11D0;
    D4: ($98, $88, $00, $60, $97, $DE, $AC, $F9));
var
  MyObject: IUnknown;
  ActiveDesk: IActiveDesktop;
  twpoComponentOpt: TComponentsOpt;
begin
  MyObject := CreateComObject(CLSID_ActiveDesktop);
  ActiveDesk := MyObject as IActiveDesktop;

  with twpoComponentOpt do
  begin
    ZeroMemory(@twpoComponentOpt, SizeOf(TComponentsOpt));
    dwSize := SizeOf(twpoComponentOpt);
    fEnableComponents := bValue;
    // fActiveDesktop := True;
  end;
  ActiveDesk.SetDesktopItemOptions(twpoComponentOpt, 0);
  ActiveDesk.ApplyChanges(AD_APPLY_ALL);
end;
patmann2001 Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 201

Windows 7 Prof.
Delphi XE2
BeitragVerfasst: Fr 06.09.02 13:04 
Klappt, danke
:mrgreen:
cu Patmann