Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How to use QProcess to open Safari on Mac

How to use QProcess to open Safari on Mac

Scheduled Pinned Locked Moved General and Desktop
3 Posts 3 Posters 3.6k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    duandcwpkt
    wrote on last edited by
    #1

    On Mac OS X, I try to use the code like this: QProcess::startDetached("/Applications/Safari.app") to open Safari, but it doesn't work! I also cut the extension to "/Applications/Safari", also doesn't work! Do somebody know why? and what's the correct method?

    1 Reply Last reply
    0
    • T Offline
      T Offline
      t3chNo
      wrote on last edited by
      #2

      i don't know about mac but if you just want to open an url, you can use QDesktopServices::openUrl(QUrl).

      1 Reply Last reply
      0
      • D Offline
        D Offline
        dakron
        wrote on last edited by
        #3

        Try with /Applications/Safari.app/Contents/MacOS/Safari

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved