Re: [Tutor] Need help on win32 application error

2013-04-02 Thread Tim Golden
On 02/04/2013 19:19, ankesh.pra...@cognizant.com wrote: I am facing folowing erro while executing python code: Win32 exception occurred releasing IUnknown at 0x03210eb8 You need to give us a bit more of a clue as to what your code does. My guess is that you're using the p

Re: [Tutor] Need help on win32 application error

2013-04-02 Thread Alan Gauld
On 02/04/13 19:19, ankesh.pra...@cognizant.com wrote: Hi Team, I am facing folowing erro while executing python code: Win32 exception occurred releasing IUnknown at 0x03210eb8 Please let me know the resolution of the same.PFA the version details of python exe that I am usin

Re: [Tutor] argparse iterable

2013-04-02 Thread kendy
I forgot about update. It's nice and clean: a.update(b) However, when 'a' has values and 'b' is None, the 'a' item gets clobbered with None. I found this on stackoverflow.com: -- old = {1: 'one', 2: 'two'} new = {1: 'newone', 2: None, 3: 'new'} old.update( (k,v) for k,v in n

Re: [Tutor] tadaahh! But how to identify zLinux?

2013-04-02 Thread eryksun
On Tue, Apr 2, 2013 at 7:19 AM, Albert-Jan Roskam wrote: >> On Windows you can also add the directory to the system PATH at >> run time. > > Ok, I'll improve that method and ditch the os.chdir calls. Win32 LoadLibrary searches system directories, the executable's directory, the current directory,

Re: [Tutor] Need help on win32 application error

2013-04-02 Thread Bod Soutar
On 2 April 2013 19:19, wrote: > Hi Team, > I am facing folowing erro while executing python code: > Win32 exception occurred releasing IUnknown at 0x03210eb8 > Please let me know the resolution of the same.PFA the version details of > python exe that I am using. > > > Thanks

[Tutor] Need help on win32 application error

2013-04-02 Thread Ankesh.Pratap
Hi Team, I am facing folowing erro while executing python code: Win32 exception occurred releasing IUnknown at 0x03210eb8 Please let me know the resolution of the same.PFA the version details of python exe that I am using. Thanks and Regards, Ankesh Pratap Programmer An

Re: [Tutor] Python help!!

2013-04-02 Thread Alan Gauld
On 02/04/13 17:49, David Mitchell wrote: How do I go through a text file, finding specific words/numbers/phrases and edit them to say different things? I do not want to edit the text file, I would rather open and read from the text file and write to a new file. OK That's easy, you just write t

Re: [Tutor] Python help!!

2013-04-02 Thread Elegbede Muhammed Oladipupo
What exactly do you know how to do? Can you read files? Can you replace words? This way, I can know how to help. What is hard for me to help with is the fact that you are planning to replace the same word with two different words depending on location e.g when you said you want to change off

Re: [Tutor] Python help!!

2013-04-02 Thread Bod Soutar
On 2 April 2013 17:49, David Mitchell wrote: > Hi! > > How do I go through a text file, finding specific words/numbers/phrases and > edit them to say different things? I do not want to edit the text file, I > would rather open and read from the text file and write to a new file. > > I do NOT want

Re: [Tutor] Python help!!

2013-04-02 Thread taserian
On Tue, Apr 2, 2013 at 12:49 PM, David Mitchell wrote: > Hi! > > How do I go through a text file, finding specific words/numbers/phrases > and edit them to say different things? I do not want to edit the text file, > I would rather open and read from the text file and write to a new file. > > I do

[Tutor] Python help!!

2013-04-02 Thread David Mitchell
Hi! How do I go through a text file, finding specific words/numbers/phrases and edit them to say different things? I do not want to edit the text file, I would rather open and read from the text file and write to a new file. I do NOT want to know how to replace a specific word with another every

Re: [Tutor] argparse iterable

2013-04-02 Thread Mark Lawrence
On 02/04/2013 10:48, Dave Angel wrote: BTW, can you tell me how you get the #the-namespace-object part of your link? Is there some technique (without actually looking in the source code for the page) for finding the nearest id= ? I've now figured out how to do it for pages like this one with a

Re: [Tutor] argparse iterable

2013-04-02 Thread eryksun
On Tue, Apr 2, 2013 at 5:48 AM, Dave Angel wrote: > > BTW, can you tell me how you get the #the-namespace-object part of your > link? Is there some technique (without actually looking in the source code > for the page) for finding the nearest id= ? 16.4.4.6. The Namespace object

Re: [Tutor] tadaahh! But how to identify zLinux?

2013-04-02 Thread Albert-Jan Roskam
> From: eryksun > To: Albert-Jan Roskam > Cc: tutor@python.org > Sent: Tuesday, April 2, 2013 4:57 AM > Subject: Re: [Tutor] tadaahh! But how to identify zLinux? > > On Mon, Apr 1, 2013 at 6:42 PM, Steven D'Aprano > wrote: >> By the way, I don't know that changing directory is a good idea, if

Re: [Tutor] tadaahh! But how to identify zLinux?

2013-04-02 Thread Albert-Jan Roskam
> Subject: Re: [Tutor] tadaahh! But how to identify zLinux? > > On 02/04/13 09:00, Alan Gauld wrote: >> On 01/04/13 21:04, Albert-Jan Roskam wrote: >> >>> program is supposed to work with zLinux (IBM system Z). But how do I >>> know that this system is used? >> >> I have no idea what the answer

Re: [Tutor] argparse iterable

2013-04-02 Thread Dave Angel
On 04/01/2013 10:28 PM, ke...@kendy.org wrote: You guys are awesome! You make it look easy and I learn every time. Once you've got the two dicts, take a look into the update method. It may make any loops unnecessary, except for debugging. -- DaveA _

Re: [Tutor] argparse iterable

2013-04-02 Thread Dave Angel
On 04/01/2013 10:34 PM, Mark Lawrence wrote: On 02/04/2013 02:37, Dave Angel wrote: On 04/01/2013 09:31 PM, Mark Lawrence wrote: for a in vars(parser.parse_args()): print('This arg is %s' % a) http://docs.python.org/3/library/argparse.html#the-namespace-object Please don't ask me for an