Forum > Editor
How to make a simple Link ?
Nisbo:
first, sorry for my bad english, but i am from germany
How to make a simple Link ?
this is my questing, i searched in google and I found for delphi:
ShellExecute(handle,nil,'http://www.google.de',nil,SW_SHOW)
shellexecute(0, 'open', 'http://www.google.de', nil, nil, sw_show);
but it doesnt work in lazarus
maybe there is an other funktion to make a simple html-link like a link to a supportpage
Nisbo:
OK no answer is also an answer :roll:
the solution is
insert inso uses: ShellAPI
and you can use
procedure TForm1.MenuItem3Click(Sender: TObject);
var sw_show: longint;
begin
Shellexecute(handle,'open',PChar('http://www.google.de'),'','',sw_show);
end;
Nisbo:
OK next question
I try to open notepad (W2K)
Shellexecute(Application.Handle,'open',PChar('C:\WINNT\NOTEPAD.EXE'),nil,nil,sw_show);
but it doesnt work, whats wrong ?
Anonymous:
Use ExecuteProcess instead
Try like this:
ExecuteProcess('C:\WINNT\NOTEPAD.EXE','');
second arguments are arguments passed to Notepad
Nisbo:
ok my mistake was that i forgot to insert Windows in units
now it works
procedure TForm1.MenuItem5Click(Sender: TObject);
begin
Shellexecute(handle,'open',PChar('http://www.google.de'),'','',sw_show);
end;
Navigation
[0] Message Index
[#] Next page