Results 1 to 2 of 2

Thread: Applicatins directory - non user specific

  1. #1
    Join Date
    Oct 2008
    Posts
    306
    Thanks
    6
    Thanked 9 Times in 8 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Applicatins directory - non user specific

    I want to get the directory to the startup programs on win menu, and using
    Qt Code:
    1. QStandardPaths::standardLocations(QStandardPaths::ApplicationsLocation).at(0)
    To copy to clipboard, switch view to plain text mode 
    returns only the applications installed for current user:

    Qt Code:
    1. C:\Users\[USERNAME]\AppData\Roaming\Microsoft\Windows\Start Menu\Programs
    To copy to clipboard, switch view to plain text mode 

    as opposed to for all users (most programs are installed here):

    Qt Code:
    1. C:\ProgramData\Microsoft\Windows\Start Menu\Programs
    To copy to clipboard, switch view to plain text mode 

    Does Qt solve this, or am I going to have to hardcode the path? Or read with winapi?

  2. #2
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Applicatins directory - non user specific

    I see no way to extract this with Qt unless a system-wide location is returned as a second entry in the standardLocations() list.

    These folders are typically the domain of installer scripts, rather than the application itself, on Windows.

Similar Threads

  1. Restrict QFileDialog to one specific directory
    By spikey in forum Qt Programming
    Replies: 2
    Last Post: 12th July 2011, 16:26
  2. Create a private directory under user
    By thru in forum Qt Programming
    Replies: 4
    Last Post: 22nd March 2011, 12:44
  3. Replies: 5
    Last Post: 14th February 2011, 14:06
  4. Fonts from specific directory
    By praveen_g in forum Newbie
    Replies: 1
    Last Post: 13th November 2009, 10:24
  5. Fonts from specific directory
    By praveen_g in forum Qt Programming
    Replies: 1
    Last Post: 13th November 2009, 10:23

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.