Ver Mensaje Individual
  #3  
Antiguo 19-05-2006
Avatar de AGAG4
AGAG4 AGAG4 is offline
Miembro
 
Registrado: ago 2004
Ubicación: Los Mochis, Sinaloa, México
Posts: 1.420
Reputación: 21
AGAG4 Va por buen camino
Ok

Haciendo pruebas con las comillas dobles, no me funciono y con el uso de la función que me recomendo, no me sirve porque me regresa direcciones cortas, ejemplo:
Código Delphi [-]
function GetShortName(sLongName: string): string; 
var 
  sShortName:    string;
  nShortNameLen: Integer; 
begin 
  SetLength(sShortName, MAX_PATH); 
  nShortNameLen := GetShortPathName(PChar(sLongName), PChar(sShortName), MAX_PATH - 1);
  if (0 = nShortNameLen) then 
  begin 
    // handle errors... 
  end; 
  SetLength(sShortName, nShortNameLen); 
  Result := sShortName; 
end; 

procedure TForm1.Button1Click(Sender: TObject); 
begin 
  Caption := GetShortName('C:\Program Files\Delphi6\Lib\test.cnt'); 
  // --> C:\PROGRA~1\Delphi6\Lib\test.cnt 
end;

Gracias por su respuesta... Sigo investigando.
Responder Con Cita