2

I use the following to open a url in a browser on Windows :

Command="C:\\Program Files\\Internet Explorer\\IEXPLORE "+Url;

Process Child=Runtime.getRuntime().exec(Command);

What should I do to achieve the same on Mac ?

Frank
  • 29,646
  • 56
  • 159
  • 233

1 Answers1

3

Try open.

String Command="open "+"http://google.ca";
Process Child=Runtime.getRuntime().exec(Command);

Hope this helps

NawaMan
  • 24,301
  • 10
  • 49
  • 75