private void saveProperties(Properties properties)
    {
        OutputStream output = null;

        try {
            output = new FileOutputStream(getAppPropertiesFileName());
            properties.store(output, "put comments here");

        } catch (IOException io) {
            io.printStackTrace();

        } finally {
            if (output != null) {
                try {
                    output.close();
                } catch (IOException io) {
                    io.printStackTrace();
                }
            }
        }
    }