![]() |
| ||
|
|
Новости |
Поиск |
FAQ |
Статьи |
Книги |
Новости VCL
| | Форумы ЧАТ |
Орешник |
|
| |||
| |||
« предыдущая ветвь | форум | следующая ветвь »
Как создать что-нибудь.lnk ?
CrazyAngel © (2002-03-28 20:02:00)Люди помогите plssss , как создать что-нибудь.lnk т.е. ярлык на мою прогу ?
CrazyAngel (2002-03-28 20:49:00) [1]>lipskiy
Спасибо , попробую ...
lipskiy (2002-03-28 20:45:00) [2]
procedure TForm1.CreateShortcut(const FilePath, ShortcutPath, WorkDir, Description, Params:string);
var
obj: IUnknown;
isl: IShellLink;
ipf: IPersistFile;
begin
obj := CreateComObject(CLSID_ShellLink);
isl := obj as IShellLink;
ipf := obj as IPersistFile;
with isl do
begin
SetPath(PChar(FilePath));
SetArguments(PChar(Params));
SetDescription(PChar(Description));
SetWorkingDirectory(PChar(WorkDir));
end;
ipf.Save(PWChar(WideString(ShortcutPath)), False);
end;