Ver Mensaje Individual
  #15  
Antiguo 11-09-2007
Avatar de paldave
paldave paldave is offline
Miembro
 
Registrado: ago 2007
Ubicación: Uruguay
Posts: 148
Reputación: 17
paldave Va por buen camino
Puedes ponerla en la sección Public de tu Form, algo así:
Código Delphi [-]
type
   TForm1 = class(TForm)
     private
     protected
     public
       function GetWindowsDir:String;
     published
   end;
y luego la implementas como:
Código Delphi [-]
function TForm1.GetWindowsDir:String;
var r,s:String;
begin
  s:=StringOfChar(#0,255);
  GetWindowsDirectory(pchar(s),255);
  result:=IncludeTrailingBackSlash(Trim(s));
end;
Responder Con Cita