[Tutor] re Python ConfigParser Tkinter PLAIN TXT ISSUE

Alan Gauld alan.gauld at yahoo.co.uk
Thu Apr 9 12:47:04 EDT 2020


On 09/04/2020 14:36, Niro One via Tutor wrote:
> Hi Alan using YMAIL at bottom switch to plain txt mode.

Yes that works. Please post using that option in future, its easier
than opening attachments - when they get through the server....


> '''mdf.py'''
> 
> import os
> import sys
> import cnf
> import tkinter as tk
> 
> 
> from configparser import ConfigParser
> 
> 
> config = ConfigParser(allow_no_value=True)
> 
> 
> cfg_key = 0
> 
> 
> if os.path.isfile('ini.ini') and os.access('ini.ini', os.R_OK):
>     try:
>         with open('ini.ini', 'r') as cfg:
>             config.read_file(cfg)

-- 
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos




More information about the Tutor mailing list