Ver Mensaje Individual
  #2  
Antiguo 25-02-2008
Avatar de dec
dec dec is offline
Moderador
 
Registrado: dic 2004
Ubicación: Alcobendas, Madrid, España
Posts: 13.142
Reputación: 36
dec Tiene un aura espectaculardec Tiene un aura espectacular
Hola,

Si entendí bien se trata de actualizar el escritorio, de modo que se muestre el nuevo icono. No sé si funcionará, pero, es posible usar cierta función de Zarko Gajic desde Inno Setup. En la sección "CODE" del "script" de Inno Setup copia lo siguiente:

Código Delphi [-]
[code]

// Constantes that we need

const
  VK_F5 = 116;
  WM_KEYUP = $0101;
  WM_KEYDOWN = $0100;

// External Win32 API functions declarations

function FindWindow(className, windowName: PChar): Integer;
 external '[email protected] stdcall';

function FindWindowEx(Parent, Child: Integer; className, windowName: PChar): Integer;
 external '[email protected] stdcall';

// Procedure to refresh the Windows desktop

procedure RefreshDesktop;
var
  hDesktop: Integer;
begin
  hDesktop := FindWindowEx(FindWindowEx(
    FindWindow('Progman', 'Program Manager'), 0,
     'SHELLDLL_DefView', ''), 0, 'SysListView32', '') ;
  PostMessage(hDesktop, WM_KEYDOWN, VK_F5, 0) ;
  PostMessage(hDesktop, WM_KEYUP, VK_F5, 1 shl 31) ;
end;

// Procedure that Inno Setup call when installation end

procedure DeinitializeSetup();
begin
  RefreshDesktop();
end;
__________________
David Esperalta
www.decsoftutils.com
Responder Con Cita