Главная страница
Top.Mail.Ru    Яндекс.Метрика
Текущий архив: 2008.02.17;
Скачать: CL | DM;

Вниз

Получить путь к объекту из ярлыка (lnk)   Найти похожие ветки 

 
IC+   (2008-01-24 16:29) [0]

СОбственно сабж. Помогите новичку. Сильно не пинайте плизз


 
Cj ©   (2008-01-24 16:34) [1]

смотри в сторону IShellLink вродебы...непомню точно...


 
Bujhm   (2008-01-25 11:15) [2]

http://read.excode.ru/art5206p1.html


 
Нафаня   (2008-01-25 12:22) [3]


function GetLnkObjectPath(const LnkFile: string): string;
const
 ValidChars: set of Char = [ #32, #33, #35..#41, #43..#46, #48..#59,
   #61, #64..#123, #125, #126, #160, #192..#255];
var
 hLnk: THandle;
 I: Integer;
 Buffer: array of Char;
 BuffLen: Integer;
 BytesCount: Cardinal;
begin
 Result := "";
 hLnk := CreateFile(PChar(LnkFile), GENERIC_READ, FILE_SHARE_READ, nil, OPEN_EXISTING, 0, 0);
 if hLnk = INVALID_HANDLE_VALUE then
   Exit;
 BuffLen := GetFileSize(hLnk, nil);
 if BuffLen > 0 then
 begin
   SetLength(Buffer, BuffLen);
   I := 0;
   while (ReadFile(hLnk, Buffer[I], 1, BytesCount, nil)) and (BytesCount > 0) do
   begin
     if Buffer[I] in ValidChars then
       Result := Result + Buffer[I]
     else if FileExists(Result) then
       Break
     else
       Result := "";    
     Inc(I);    
   end;
   Finalize(Buffer);
 end;          
 CloseHandle(hLnk);
end;



Страницы: 1 вся ветка

Текущий архив: 2008.02.17;
Скачать: CL | DM;

Наверх




Память: 0.47 MB
Время: 0.021 c
15-1200380983
Карелин Артем
2008-01-15 10:09
2008.02.17
Delphi 7 и Crystal Reports 11


15-1200313761
Human
2008-01-14 15:29
2008.02.17
аналог VMware Converter но для Virtual PC 2007


2-1201174029
Тоник
2008-01-24 14:27
2008.02.17
listbox с картинками в итемах


2-1200923194
zeroed
2008-01-21 16:46
2008.02.17
Распарсить строку


15-1200298824
alexeis
2008-01-14 11:20
2008.02.17
не соответствие клавиш в DOSe