xtd 0.2.0
Loading...
Searching...
No Matches

◆ save_as() [1/2]

void xtd::configuration::file_settings::save_as ( const xtd::string file_path)

Save current settings in the specified file path.

Parameters
file_pathThe file to save the current settings.
Remarks
The settings are saved in the specified settings file.
Examples
The following example shows how to create xtd::configuration::file_settings and use xtd::configuration::file_settings::write and xtd::configuration::file_settings::save_as methods.
auto file = file_settings {};
file.write("pictures \"Menu\"", "file_open", "resources/symbolic_open.png");
file.write("pictures \"Menu\"", "file_save", "resources/symbolic_save.png");
file.save_as("my_app.ini")
void write(const xtd::string &key, const xtd::string &value) noexcept
Writes a specified value for specified key in the global section.
Represents an object for storing and retrieving configuration information using text files in INI for...
Definition file_settings.h:32
my_app.ini:
[pictures "Menu"]
file_open = resources/symbolic_open.png
file_save = resources/symbolic_save.png