Read INI-File

Bernard Delmée nobody at home.net
Wed Feb 28 17:34:04 EST 2001


Your example works fine for me, on W2K, (prints 'timer.drv')
ActivePython 2.0, build 202

I tried both SetProfileFileName('C:\\WINNT\\system.ini')
and SetProfileFileName('C:/WINNT/system.ini')


"Marc Vollmer" <marc.vollmer at mahr.de> wrote in message
news:97ia2t$p9da2$1 at ID-59219.news.dfncis.de...
> Thanks,
>
> but no solution, perhaps my computer don't understand me.
>
> So, I test it with the system.ini in the c:\winnt\.
>
> Please test it, too. Perhaps it is a windows 2k problem? I don't know,
what
> I still could do.
>
> --
> import win32ui
> win32ui.SetProfileFileName('C:\\WINNT\\system.ini')
> k=win32ui.GetProfileVal('drivers','timer','xxx')
> print k
> --
>
> My result is: xxx and yours?
>
> Regards
> Marc
>
>
> "Werner Schiendl" <ws-news at gmx.at> schrieb im Newsbeitrag
> news:983288899.644740 at newsmaster-04.atnet.at...
> >
> > Marc Vollmer <marc.vollmer at mahr.de> wrote in message
> > news:97ggqk$p53ii$1 at ID-59219.news.dfncis.de...
> > > No chance:
> > >
> > > I try:
> > >
> > > win32ui.SetProfileFileName('c:\winnt\test.ini')
> >
> > If you _really_ wrote it this way it will not work.
> > The backslashes are used to escape the values.
> >
> > Use    'c:\\winnt\\test.ini'
> > or    r'c:\winnt\test.ini'
> >
> > hth
> > werner
> >
> >
>
>





More information about the Python-list mailing list