(Gast)
n/a Beiträge
|
3. Jul 2003, 00:07
Bitte sehr:
Delphi-Quellcode:
function ShortFileName(const Path: string): PChar;
var
Tmp: array[0..MAX_PATH + 1] of Char;
begin
if (GetShortPathName(PChar(Path), Tmp, SizeOf(Tmp) - 1) = 0) then
Result := PChar(Path)
else
Result := Tmp;
end;
procedure TForm1.Button1Click(Sender: TObject);
var
Path: string;
begin
Path := 'C:\Eigene Dateien\Eigene Programme\*.*';
SendMessage(ListBox1.Handle, LB_DIR, DDL_READWRITE, lParam(ShortFileName(Path)));
end;
|
|
|