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. QSettings delete registry path
Forum Updated to NodeBB v4.3 + New Features

QSettings delete registry path

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 3 Posters 1.8k Views 1 Watching
  • 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.
  • M Offline
    M Offline
    MartinD
    wrote on last edited by
    #1

    Hi,
    I store settings of my Win app in registry:

    HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key1 = something
    HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key2 = something
    HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key2 = something

    Now I want to delete these records completely from registry. Is it possible to delete whole path HKEY_CURRENT_USER\SOFTWARE\Company in Qt ?

    kshegunovK raven-worxR 2 Replies Last reply
    0
    • M MartinD

      Hi,
      I store settings of my Win app in registry:

      HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key1 = something
      HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key2 = something
      HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key2 = something

      Now I want to delete these records completely from registry. Is it possible to delete whole path HKEY_CURRENT_USER\SOFTWARE\Company in Qt ?

      kshegunovK Offline
      kshegunovK Offline
      kshegunov
      Moderators
      wrote on last edited by
      #2

      @MartinD said in QSettings delete registry path:

      Is it possible to delete whole path HKEY_CURRENT_USER\SOFTWARE\Company in Qt

      I don't believe so.

      Now I want to delete these records completely from registry.

      https://msdn.microsoft.com/en-us/library/windows/desktop/ms724845(v=vs.85).aspx

      Read and abide by the Qt Code of Conduct

      1 Reply Last reply
      0
      • M MartinD

        Hi,
        I store settings of my Win app in registry:

        HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key1 = something
        HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key2 = something
        HKEY_CURRENT_USER\SOFTWARE\Company\Product\Key2 = something

        Now I want to delete these records completely from registry. Is it possible to delete whole path HKEY_CURRENT_USER\SOFTWARE\Company in Qt ?

        raven-worxR Offline
        raven-worxR Offline
        raven-worx
        Moderators
        wrote on last edited by
        #3

        @MartinD said in QSettings delete registry path:

        Now I want to delete these records completely from registry. Is it possible to delete whole path HKEY_CURRENT_USER\SOFTWARE\Company in Qt ?

        i can't tell for sure that it works, but why not simply try it?

        QSettings("HKEY_CURRENT_USER\\SOFTWARE\\Company", QSettings::NativeFormat).remove(".");
        

        --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
        If you have a question please use the forum so others can benefit from the solution in the future

        1 Reply Last reply
        3

        • Login

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