473,324 Members | 2,196 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

Reading config.ini in PythonWin.

1
Hi,

I am new in Python Forum and quite new in Python programming as well. I
am working mainly with GIS and using Esri's geoprocessing tools.

I want to use .ini file to set the parameters, especially paths, in my
project. PythonWin 2.1. is my version. Windows is XP.

Why do I get the default back in the case below? Any way around?

The Paths,Temp is c:/temp.

>>> win32ui.SetProfileFileName('D:\\config.ini')
>>> Temp = win32ui.GetProfileVal('Paths','Temp','c:/')
>>> print Temp
c:/
>>>

W.
Sep 4 '06 #1
0 1957

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Moth | last post by:
I have a web application that needs to read an xml configuration file. How can I specify this without knowing the path of the web application? I've tried using...
4
by: Fuzzyman | last post by:
There have been a couple of config file 'systems' announced recently, that focus on building more powerful and complex configuration files. ConfigObj is a module to enable you to much more *simply*...
3
by: Marek | last post by:
Hi there, my WinForm application has to be installed in "no-touch-deployment" mode, so users can run it from the web. I need to read application's .config file but it does not work in ...
4
by: Jon Maz | last post by:
Hi All, I'm getting to grips with PHP and Apache (on Windows for current development, production site will be on Linux), and have a simple (I hope!) request. When you change the httpd.conf...
2
by: jassi | last post by:
Hi, i have an app.config file as follows : <?xml version="1.0" encoding="utf-8"> <configuration> <appSettings> <add key="button1.Text" value="cc1"/>
0
by: jason | last post by:
here is my config file (myapp.exe.config): <configuration> <startup> <supportedRuntime version="v1.1.4322" /> </startup> <appSettings> <add key="success" value="1" /> <add key="failure"...
3
by: Søren M. Olesen | last post by:
Hi I've created a Class library (myClasses.dll), and added a settings.settings to it using designer. However when I use this class library, it doesn't seem to read the settings...
0
by: Salty Dog | last post by:
I have the config file named properly but maybe I don't have it in the proper location. I have it in the root of the project folder. Is there someplace that I need to configure the Windows...
1
by: Vesa Leppanen | last post by:
Hi, I am new in python-list and quite new in Python programming as well. I am working mainly with GIS and using Esri's geoprocessing tools. I want to use .ini file to set the parameters,...
1
by: M Irfan | last post by:
Hello all, Recently I have started working in .NET 2.0. I am developing a web service application that references a DLL component written in C# 2.0. The component has its own config file which...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.