Results 1 to 2 of 2

Thread: .INI file

  1. #1
    Join Date
    Jul 2017

    Default .INI file

    Hello every1,
    I have an config.ini file which contains information about a car, and a path to a route.
    it starts like

    How do I use Qsettings to read that path, so I can access the file from that path.
    The file from that path is a CSV file from which I have to read other values which will be
    used in formulas for other things.

    Any1 who have an idea please tell me, I'm very dummy on Qt I've just started working with it.

  2. #2
    Join Date
    Mar 2008
    Kraków, Poland
    Thanked 277 Times in 272 Posts
    Qt products
    Unix/X11 Windows

    Default Re: .INI file

    Qt Code:
    1. QSettings my_ini_file( path_to_ini_file, QSettings::IniFormat );
    2. QString my_file_path = my_ini_file.value("root/inputfile().toString();
    To copy to clipboard, switch view to plain text mode 

  3. The following user says thank you to Lesiok for this useful post:

    durus90 (26th July 2017)

Similar Threads

  1. Replies: 2
    Last Post: 13th January 2014, 07:27
  2. Replies: 4
    Last Post: 2nd October 2013, 13:57
  3. Replies: 4
    Last Post: 9th May 2010, 16:18
  4. Replies: 3
    Last Post: 28th March 2009, 15:37
  5. Replies: 3
    Last Post: 25th May 2007, 07:49

Tags for this Thread


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.