Recent

Author Topic: [SOLVED]shellexec replacement  (Read 5634 times)

mbnoimi

  • New Member
  • *
  • Posts: 34
[SOLVED]shellexec replacement
« on: October 23, 2010, 11:24:08 am »
Hi All,

I usually use shellexec in Windows in "onclick" event for opening links is there any replacement for opening links in LCL?

PS
I'm afraid that shellexec will not works in Linux.
« Last Edit: October 26, 2010, 08:44:46 am by mbnoimi »

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: shellexec replacement
« Reply #1 on: October 23, 2010, 11:28:32 am »
ShellExecute has an implementation in Lazarus, but use OpenURL instead.

mbnoimi

  • New Member
  • *
  • Posts: 34
Re: shellexec replacement
« Reply #2 on: October 23, 2010, 11:53:08 am »
Quote
ShellExecute has an implementation in Lazarus
you mean I can use ShellExecute safety in Linux, is it?

typo

  • Hero Member
  • *****
  • Posts: 3051
Re: shellexec replacement
« Reply #3 on: October 23, 2010, 12:18:43 pm »
No.


theo

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1918
Re: shellexec replacement
« Reply #5 on: October 23, 2010, 12:35:35 pm »
Use
  OpenDocument(Filename);
or
  OpenURL(FileName);

Both in unit LCLIntf (at least in Lazarus 0.9.29)

mbnoimi

  • New Member
  • *
  • Posts: 34
[SOLVED]Re: shellexec replacement
« Reply #6 on: October 26, 2010, 08:42:33 am »
Thanks a lot for your replies the problem solved.

 

TinyPortal © 2005-2018