Re: Newbie question about sending and receiving data to the command prompt.

2008-08-19 Thread Gabriel Genellina
En Tue, 19 Aug 2008 16:48:26 -0300, aditya shukla <[EMAIL PROTECTED]> escribi�: I am using windows vista and i am trying to send data to the command prompt ,this is what is done. import subprocess proc =subprocess.Popen('cmd.exe',stdin=subprocess.PIPE) proc.communicate('abc') when i run thi

Re: how to add property "dynamically"?

2008-08-19 Thread Gabriel Genellina
En Tue, 19 Aug 2008 15:02:29 -0300, Rafe <[EMAIL PROTECTED]> escribió: On Aug 17, 5:09 pm, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: akonsu a écrit :> hello, > i need to add properties to instances dynamically during run time. Properties must be class attributes. The only way (the only

Re: searching through a string and pulling characters

2008-08-19 Thread Sean DiZazzo
On Aug 19, 6:11 am, Wojtek Walczak <[EMAIL PROTECTED]> wrote: > On Mon, 18 Aug 2008 15:34:12 -0700 (PDT), Alexnb wrote: > > Also, on a side-note, does anyone know a very simple dictionary site, that > > isn't dictionary.com or yourdictionary.com. > > This one is my favourite:http://www.lingro.com/

Re: who to call a list of method inside the class itself

2008-08-19 Thread Gabriel Genellina
En Tue, 19 Aug 2008 11:18:00 -0300, <[EMAIL PROTECTED]> escribi�: Is the following code is ok. who to call all method. It is working but the call to m() without a reference to self seems strange Ok, so you already know it works - and you want to know why! class CustomMethod: def method1(

回复: How to use win32com to co nvert a MS WORD doc to HTML ?

2008-08-19 Thread Lave
HUH! :) It's solved. Thank you all! You saved my life! Thank you very much. I love you! I love Python! 2008/8/20, Simon Brunning <[EMAIL PROTECTED]>: > 2008/8/19 Lave <[EMAIL PROTECTED]>: >> Hi, all ! >> >> I'm a totally newbie huh:) >> >> I want to convert MS WORD docs to HTML, I found python

Re: exception handling in complex Python programs

2008-08-19 Thread eliben
""" between file() and open() in Python 2 and 3, a NameError is thrown with open() in Python 3 and an IOError is thrown in the other three cases . """ This is *exactly* my concern with Python exceptions. You just never know what can be thrown at you. > You want to look up Easier to Ask Forgivness

Discrete Simulation

2008-08-19 Thread Tim Roberts
Rather than post a question seeking a solution, I thought I would post a recommendation. I needed to run a simulation of a USB device today, trying to decide whether a device we are building could work with an isochronous pipe in unfavorable conditions without overflowing its FIFOs. I was just ab

Re: Display the results of a query to an html table

2008-08-19 Thread alex23
On Aug 20, 12:35 am, Amie <[EMAIL PROTECTED]> wrote: > how do you display the results of an sql query and display it onto the > html form or html table You might want to give people time to actually respond to the original thread in which you asked this question, rather than spawning a new one thr

Re: Python Query: Related to locking a resource in a multithreaded environment

2008-08-19 Thread Gabriel Genellina
En Tue, 19 Aug 2008 15:58:11 -0300, Nils Oliver Kröger <[EMAIL PROTECTED]> escribi�: My approach what be to write one class for reading and writing to the configuration and make that class thread-safe using the RLock. Then you create one and only one instance of this class and let all your th

Re: Grandchildren of TestCase don't work

2008-08-19 Thread infixum
Gustavo Narea wrote: > Hello, everyone. > > Why do unitest.TestCase grand-grandchildren not work? > > I've created a unittest.TestCase descendant, which contains the setUp() and > tearDown() for testing some components of a web framework. Every > application based on this framework should subclas

Re: The Jihad Candidate

2008-08-19 Thread thermate2
DUDE, have you gone mad ? The ZIONIST MEDIA never barked that it was a jew or a yank bastard when those fake anthrax letters were mailed. 911 was an inside job. Thermate cutter charges were used by yank bastards themselves. The media never did their job for the people or truth. It did it for the co

IOError: decoder zip not available when using PIL

2008-08-19 Thread YouOverThere
I keep getting the error message "IOError: decoder zip not available" when using the Python Imaging Library. The error has occurred when trying to work with PNGs or JPEGs or when loading the fonts supplied with PIL. I can work with GIFs. I assume that I did something wrong when I built Python and/o

Storing Passwords

2008-08-19 Thread Eric Wertman
I've a number of scripts set up that require a username/password combination to log in elsewhere. It's gotten to the point where I need to keep them in a more secure location, instead of just in the scripts themselves. I did a bit of searching, and haven't come up with a great way to store passwo

Professional Grant Proposal Writing Workshop (September 2008: British Columbia Institute of Technology - Vancouver Campus)

2008-08-19 Thread Anthony Jones
The Grant Institute's Grants 101: Professional Grant Proposal Writing Workshop will be held at the British Columbia Institute of Technology - Vancouver Campus, September 29 - October 1, 2008. Interested development professionals, researchers, faculty, and graduate students should register as soo

Subprocess module question.

2008-08-19 Thread aditya shukla
Hello folks, I am using windows vista and i am trying to communicate with various processes. so when i do import subprocess proc=subprocess.Popen('cmd.exe') --This opens the command prompt But when i do proc=subprocess.Popen('netscan.exe') it gives an error Traceback (most recent call last):

Re: exception handling in complex Python programs

2008-08-19 Thread Steven D'Aprano
On Tue, 19 Aug 2008 11:07:39 -0700, [EMAIL PROTECTED] wrote: > def do_something(filename): > if not os.access(filename,os.R_OK): > return err(...) > f = open(filename) > ... You're running on a multitasking modern machine, right? What happens when some other process deletes

Re: How to stop iteration with __iter__() ?

2008-08-19 Thread John Machin
On Aug 20, 5:06 am, Terry Reedy <[EMAIL PROTECTED]> wrote: > In your case, the standard Python idiom, as Jon said, is > > it = iter(iterable) > next(it) # 2.6, 3.0 > for for item in iterable: >f(item) or, perhaps, for completeness/paranoia/whatever: it = iter(iterable) try: headings = it.n

Tkinter and TableList - Configure the Temporary Embedded Widgets

2008-08-19 Thread lee . walczak
I actually post a topic relating to my problem here: (http://groups.google.co.uk/group/comp.lang.python/browse_thread/ thread/a073d532c4481bfe?hl=en# ) But I thought it could be useful to place an example of my problem here aswell. This a small piece of testcode that creates a TableList. When the

Re: who to call a list of method inside the class itself

2008-08-19 Thread Terry Reedy
[EMAIL PROTECTED] wrote: Is the following code is ok. who to call all method. It is working but the call to m() without a reference to self seems strange The reference to self is bound to the methods by the way you look them up. class CustomMethod: def method1(self): d

Re: displaying my randomly selected numbers in a colorful interface.

2008-08-19 Thread Goksie Aruna
Mike Driscoll wrote: On Aug 19, 1:02 am, Goksie Aruna <[EMAIL PROTECTED]> wrote: dear all, i have arrays of number of size lets say 4000 i.e. 201000..2013999 now i want to do the following. first print all the numbers to a colorful console. be it wx, tk, or web based. then pick a winni

Grandchildren of TestCase don't work

2008-08-19 Thread Gustavo Narea
Hello, everyone. Why do unitest.TestCase grand-grandchildren not work? I've created a unittest.TestCase descendant, which contains the setUp() and tearDown() for testing some components of a web framework. Every application based on this framework should subclass this base class once, and the res

Re: urllib getting SSL certificate info

2008-08-19 Thread Ghirai
On Wednesday 20 August 2008 00:05:47 Jean-Paul Calderone wrote: > I don't know about M2Crypto. Here's some sample code for PyOpenSSL: > > from socket import socket > from OpenSSL.SSL import Connection, Context, SSLv3_METHOD > s = socket() > s.connect(('google.com', 443)) > c = Connectio

Good approximate static function call analyzer

2008-08-19 Thread Dan Yamins
I'm looking for a reasonable static function call analysis tool for python functions -- something that will look at code (and possibly import the module it's in) and return a reasonable guess at the functions that might be called by the code. For my purposes, approximations are totally fine -- e.g

Re: Handling Property and internal ('__') attribute inheritance and creation

2008-08-19 Thread Bruno Desthuilliers
Rafe a écrit : On Aug 16, 1:22 am, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: Rafea écrit : Hi, I've been thinking in circles about these aspects of Pythonic design and I'm curious what everyone else is doing and thinks. There are 3 issues here: 1) 'Declaring' attributes There's nothing l

Re: urllib getting SSL certificate info

2008-08-19 Thread Jean-Paul Calderone
On Tue, 19 Aug 2008 23:06:30 +0300, Ghirai <[EMAIL PROTECTED]> wrote: On Sunday 17 August 2008 20:15:47 John Nagle wrote: If you really need details from the SSL cert, you usually have to use M2Crypto. The base SSL package doesn't actually do much with certificates. It doesn't validate the

Re: You advice please

2008-08-19 Thread Bruno Desthuilliers
Hussein B a écrit : On Aug 15, 10:05 am, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: Hussein B a écrit : (snip) But this critisim looks so serious: http://en.wikipedia.org/wiki/Ruby_programming_language#Criticism Most of what's written here could apply to Python too - all the part which mo

Re: AOP in Python

2008-08-19 Thread Bruno Desthuilliers
Hussein B a écrit : Hey, AOP is build in Groovy language via many means, does Python support AOP out of the box without the need for such tools: http://pythonsource.com/open-source/aspect-oriented-frameworks Thanks. See the use of @decorators in most Python frameworks. When functions are first

Re: who to call a list of method inside the class itself

2008-08-19 Thread Bruno Desthuilliers
[EMAIL PROTECTED] a écrit : [EMAIL PROTECTED] wrote: Hi, Is the following code is ok. who to call all method. It is working but the call to m() without a reference to self seems strange Thanks for your help class CustomMethod: def method1(self): def method2(self):

Re: urllib getting SSL certificate info

2008-08-19 Thread Ghirai
On Sunday 17 August 2008 20:15:47 John Nagle wrote: > If you really need details from the SSL cert, you usually have to use > M2Crypto. The base SSL package doesn't actually do much with certificates. > It doesn't validate the certificate chain. And those strings of > attributes you can get

Idle is not accepting backslashes on some Mac OSX keyboards

2008-08-19 Thread mounty
Hi list, I am using a German keyboard on Mac OS X 10.4.11. Idle 1.2.2 is constantly blocking entering the backslash character '\' which is for instance perfectly accepted by my mail application, as you can see for yourself. If I switch to an US, Australian or English keyboard layout the backsla

Newbie question about sending and receiving data to the command prompt.

2008-08-19 Thread aditya shukla
Hello folks, I am using windows vista and i am trying to send data to the command prompt ,this is what is done. import subprocess proc =subprocess.Popen('cmd.exe',stdin=subprocess.PIPE) proc.communicate('abc') when i run this the command prompt just blinks and disappears , can anyone explain what

Re: displaying my randomly selected numbers in a colorful interface.

2008-08-19 Thread Mike Driscoll
On Aug 19, 1:02 am, Goksie Aruna <[EMAIL PROTECTED]> wrote: > dear all, > > i have arrays of number of size lets  say 4000 i.e.  201000..2013999 > > now i want to do the following. > > first print all the numbers to a colorful console. be it wx,  tk, or web > based. > > then pick a winning number f

Re: How to stop iteration with __iter__() ?

2008-08-19 Thread Terry Reedy
ssecorp wrote: I want a parse a file of the format: movieId customerid, grade, date customerid, grade, date customerid, grade, date etc. so I could do with open file as reviews and then for line in reviews. but first I want to take out the movie id so I use an iterator. then i want to iterat

Re: Python Query: Related to locking a resource in a multithreaded environment

2008-08-19 Thread Nils Oliver Kröger
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi, I don't think the global interpreter lock is what you need ... read here for reference: http://docs.python.org/api/threads.html My approach what be to write one class for reading and writing to the configuration and make that class thread-safe u

Re: HTML Tables

2008-08-19 Thread Stefan Behnel
Amie wrote: > Thanks for your help so far. Ok here's a scenario: I have to create a > site that displays 34 html tables. > In each of these tables the following information has to be displayed: > logo (image), site name, date, time. > Remember: in all of these 34 tables. the information displayed

Re: Getting pid of a remote process

2008-08-19 Thread Kurt Mueller
srinivasan srinivas schrieb: Thanks a lot. But i am wondeing will it return correct pid if more than one instance of run on the remote machine?? Thanks, Srini On UNIX-like OS: If you start the process in the background, you can get the PID with: :~> ssh 'ls -l & echo PID=$!' | grep PID PI

displaying my randomly selected numbers in a colorful interface.

2008-08-19 Thread Goksie Aruna
dear all, i have arrays of number of size lets say 4000 i.e. 201000..2013999 now i want to do the following. first print all the numbers to a colorful console. be it wx, tk, or web based. then pick a winning number from the range which will now be printed at the center of the page. how

Re: cathing uncaught exceptions

2008-08-19 Thread Gabriel Genellina
En Mon, 18 Aug 2008 12:02:29 -0300, Alexandru Mosoi <[EMAIL PROTECTED]> escribió: > how can I catch (globally) exception that were not caught in a try/ > catch block in any running thread? i had this weird case that an > exception was raised in one thread, but nothing was displayed/logged. Each

Re: Python encoding

2008-08-19 Thread Joan Pallarès
Sorry, The problem is the OblecjtListView doesn't show some characters correctly. In the image attached, in the "partidos list" in the grey line, where a square is showed it must be a Ç And in the second line where a | is showed it should be a ª Why this happen? maybe OLV doesn`t manage well the

Re: Graphics Contexts and DCs explanations?

2008-08-19 Thread Chris Mellon
On Tue, Aug 19, 2008 at 1:16 PM, RgeeK <[EMAIL PROTECTED]> wrote: > Experimenting with graphics in an app: it's AUI based with a few panes, one > of which has a panel containing a few sizers holding UI elements. One sizer > contains a panel that needs some basic line-drawing graphics in it. > > I u

Graphics Contexts and DCs explanations?

2008-08-19 Thread RgeeK
Experimenting with graphics in an app: it's AUI based with a few panes, one of which has a panel containing a few sizers holding UI elements. One sizer contains a panel that needs some basic line-drawing graphics in it. I use the wxPython demo app heavily to figure this stuff out, and my expe

Re: Programming Languages Decisions

2008-08-19 Thread E.D.G.
"Lie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] How is Python with graphics? pygame for graphic with SDL library (e.g. fullscreen apps, hardware accelerated) Tkinter for basic GUI that can run on any python with no dependencies (except python vm) wxWidget, etc for more advance

Re: exception handling in complex Python programs

2008-08-19 Thread [EMAIL PROTECTED]
On Aug 19, 10:19 am, eliben <[EMAIL PROTECTED]> wrote: > P.S. There's a common case where a method is passed a filename, to do > something with a file (say, read data). Should the method catch the > errors possibly thrown by open(), or leave it to the caller ? You want to look up Easier to Ask Fo

Re: how to add property "dynamically"?

2008-08-19 Thread Rafe
On Aug 17, 5:09 pm, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: > akonsu a écrit :> hello, > > > i need to add properties to instances dynamically during run time. > > this is because their names are determined by the database contents. > > so far i found a way to add methods on demand: > > > c

Re: adding properties dynamically (how to?)

2008-08-19 Thread Rafe
On Aug 17, 7:51 pm, André <[EMAIL PROTECTED]> wrote: > I didn't want to hijack the original thread but I have basically the > same request... > > On Aug 17, 7:09 am, Bruno Desthuilliers<[EMAIL PROTECTED]> wrote: > > akonsu a écrit :> hello, > > [SNIP] > > > > > Wrong solution to your problem, I'd s

Re: adding properties dynamically (how to?)

2008-08-19 Thread Rafe
On Aug 17, 7:51 pm, André <[EMAIL PROTECTED]> wrote: > I didn't want to hijack the original thread but I have basically the > same request... > > On Aug 17, 7:09 am, Bruno Desthuilliers<[EMAIL PROTECTED]> wrote: > > akonsu a écrit :> hello, > > [SNIP] > > > > > Wrong solution to your problem, I'd s

Re: exception handling in complex Python programs

2008-08-19 Thread Fredrik Lundh
Rafe wrote: Again, this is probably too simple to help, but the only way to ignore certain types of exceptions, as far as I know, is to catch them and pass. e.g. this ignores type errors... try: somethingBad() except TypeError, err: pass except Exception, err: raise TypeError(err)

Re: cathing uncaught exceptions

2008-08-19 Thread Rafe
On Aug 18, 10:02 pm, Alexandru Mosoi <[EMAIL PROTECTED]> wrote: > how can I catch (globally) exception that were not caught in a try/ > catch block in any running thread? i had this weird case that an > exception was raised in one thread, but nothing was displayed/logged. Any chance you might hav

Re: HTML Tables

2008-08-19 Thread Mensanator
On Aug 19, 9:33 am, Amie <[EMAIL PROTECTED]> wrote: > Hi, > Thanks for your help so far. Ok here's a scenario: I have to create a > site that displays 34 html  tables. > In each of these tables the following information has to be displayed: > logo (image), site name, date, time. You want 34 tables

Re: exception handling in complex Python programs

2008-08-19 Thread Rafe
On Aug 20, 12:19 am, eliben <[EMAIL PROTECTED]> wrote: > Python provides a quite good and feature-complete exception handling > mechanism for its programmers. This is good. But exceptions, like any > complex construct, are difficult to use correctly, especially as > programs get large. > > Most of

Re: exception handling in complex Python programs

2008-08-19 Thread Chris Mellon
On Tue, Aug 19, 2008 at 12:19 PM, eliben <[EMAIL PROTECTED]> wrote: > Python provides a quite good and feature-complete exception handling > mechanism for its programmers. This is good. But exceptions, like any > complex construct, are difficult to use correctly, especially as > programs get large.

Re: Programming Languages Decisions

2008-08-19 Thread Lie
On Aug 19, 1:45 pm, "E.D.G." <[EMAIL PROTECTED]> wrote: > "Terry Reedy" <[EMAIL PROTECTED]> wrote in message > > news:[EMAIL PROTECTED] > > > Rather than explain further, I suggest that you visit python.org and read > > some of the tutorial to see what *you* think. > >http://docs.python.org/tut/tut

Re: What parts of C:\Python25 are important?

2008-08-19 Thread Fredrik Lundh
Robert Dailey wrote: I've currently embedded the python interpreter into a C++ application of mine. I want to bundle the python core library with my application so the user does not have to install python to use my application. What files do I need to copy over? Help is appreciated, thank you.

exception handling in complex Python programs

2008-08-19 Thread eliben
Python provides a quite good and feature-complete exception handling mechanism for its programmers. This is good. But exceptions, like any complex construct, are difficult to use correctly, especially as programs get large. Most of the issues of exceptions are not specific to Python, but I sometim

What parts of C:\Python25 are important?

2008-08-19 Thread Robert Dailey
Hi, I've currently embedded the python interpreter into a C++ application of mine. I want to bundle the python core library with my application so the user does not have to install python to use my application. What files do I need to copy over? Help is appreciated, thank you. -- http://mail.pytho

Re: ANN: Resolver One 1.2 released

2008-08-19 Thread Giles Thomas
2008/8/19 km <[EMAIL PROTECTED]> Hi, sounds great - but disappointing to find it only available on window$. Is there any Linux release in near future ??? KM Not in the near future, unfortunately - but we're looking at getting it running under Mono in the medium term. The big probl

Re: datetime.datetime.now() in military time

2008-08-19 Thread Mike Driscoll
On Aug 19, 10:42 am, korean_dave <[EMAIL PROTECTED]> wrote: > import datetime > > def main(): >     timenow = datetime.datetime.now() >     print(str(timenow.hour)) > > if __name__ == "__main__": >     main() > > If the time was, say, 2pm, how can I make output of timenow.hour "14" > instead of "2"

Re: who to call a list of method inside the class itself

2008-08-19 Thread Diez B. Roggisch
[EMAIL PROTECTED] wrote: > [EMAIL PROTECTED] wrote: >> >> [EMAIL PROTECTED] wrote: >> >> > 1. return string names of required methods in getAllMethod >> > return ['method1', 'method2', 'method3'] >> > 2. use gettattr on self and then exetute methods in applyAll >> > def applyAll(self): >> > for

Re: who to call a list of method inside the class itself

2008-08-19 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: ensure instance's method invocation with all > state information to that point, rather than > relying on implemenation. Did you read the stuff I wrote about "bound methods" in the other post? That's a fundamental Python feature, not an implementation artifact. For

Re: How to use win32com to convert a MS WORD doc to HTML ?

2008-08-19 Thread Simon Brunning
2008/8/19 Lave <[EMAIL PROTECTED]>: > Hi, all ! > > I'm a totally newbie huh:) > > I want to convert MS WORD docs to HTML, I found python windows > extension win32com can make this. But I can't find the method, and I > can't find any document helpful. This should be a useful starting point:

Re: How to use win32com to convert a MS WORD doc to HTML ?

2008-08-19 Thread Tim Golden
Lave wrote: Hi, all ! I'm a totally newbie huh:) I want to convert MS WORD docs to HTML, I found python windows extension win32com can make this. But I can't find the method, and I can't find any document helpful. You have broadly two approaches here, both involving automating Word (ie using

Re: who to call a list of method inside the class itself

2008-08-19 Thread Edwin . Madari
[EMAIL PROTECTED] wrote: > > [EMAIL PROTECTED] wrote: > > > 1. return string names of required methods in getAllMethod > > return ['method1', 'method2', 'method3'] > > 2. use gettattr on self and then exetute methods in applyAll > > def applyAll(self): > > for method_name in self.

Re: Factory for Struct-like classes

2008-08-19 Thread eliben
On Aug 18, 11:16 am, Gabriel Genellina <[EMAIL PROTECTED]> wrote: > On 13 ago, 14:46, eliben <[EMAIL PROTECTED]> wrote: > > > On Aug 13, 7:30 pm, Christian Heimes <[EMAIL PROTECTED]> wrote: > > > > eliben wrote: > > > > Ruby's 'Scruct' class (http://ruby-doc.org/core/classes/Struct.html) > > > > do

datetime.datetime.now() in military time

2008-08-19 Thread korean_dave
import datetime def main(): timenow = datetime.datetime.now() print(str(timenow.hour)) if __name__ == "__main__": main() If the time was, say, 2pm, how can I make output of timenow.hour "14" instead of "2"? Thanks. -Dave -- http://mail.python.org/mailman/listinfo/python-list

Cash Master

2008-08-19 Thread hello_mox_10
Cash Master I've made £1260 in one week using this system and you could too. Now in its fifth year, this Best Seller continues to transform thousands of ordinary peoples lives, and you can join them! NO prior knowledge or experience in the betting industry. A basic internet connection, dial-up

Re: who to call a list of method inside the class itself

2008-08-19 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: 1. return string names of required methods in getAllMethod return ['method1', 'method2', 'method3'] 2. use gettattr on self and then exetute methods in applyAll def applyAll(self): for method_name in self.getAllMethod(): method

Re: Eggs and Gems

2008-08-19 Thread Mike Driscoll
On Aug 19, 8:19 am, Hussein B <[EMAIL PROTECTED]> wrote: > Hey, > Are Python eggs and RubyGems do the same thing (of course Gems is for > Ruby and eggs is for Python)? > If yes, is it outstanding as the RubyGems? > Thanks. I've never used Ruby, so I can't say for sure, but I think they're close. R

Re: Display the results of a query to an html table

2008-08-19 Thread Marco Nawijn
On Aug 19, 4:35 pm, Amie <[EMAIL PROTECTED]> wrote: > Hi, > how do you display the results of an sql query and display it onto the > html form or html table > > Thanks Hello, You might want to take a look at: sqlobject http://www.sqlobject.org/ or sqlalchemy http://www.sqlalchemy.org/ Th

Re: who to call a list of method inside the class itself

2008-08-19 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: def getAllMethod(self): return [self.method1, self.method2, self.method3] def applyAll(self): for m in self.getAllMethod(): # how to call all methods ? # is it correct m() what happens when you run the code?

Re: who to call a list of method inside the class itself

2008-08-19 Thread Edwin . Madari
[EMAIL PROTECTED] wrote: > Hi, > > Is the following code is ok. who to call all method. > It is working but the call to m() without a reference to self seems > strange > > Thanks for your help > > class CustomMethod: > def method1(self): > > def method2(self): > ...

Re: who to call a list of method inside the class itself

2008-08-19 Thread maduma
On Aug 19, 4:33 pm, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > Is the following code is ok. who to call all method. > > It is working but the call to m() without a reference to self seems > > strange > > > Thanks for your help > > > class CustomMethod: > > def metho

Re: How to access an Array and a struct within a struct wrapped by Swig ?

2008-08-19 Thread jparker104
On Aug 17, 11:30 pm, [EMAIL PROTECTED] wrote: > Anish Chapagain, I already know how to use structure, as my example > shown it. > I had trouble only with the nested structures, and it was coz of > missing typedef (ie: Swig need C struct declaration, not C++). > > And I still cannot find how to get

Re: Handling Property and internal ('__') attribute inheritance and creation

2008-08-19 Thread Rafe
On Aug 16, 1:22 am, Bruno Desthuilliers <[EMAIL PROTECTED]> wrote: > Rafea écrit : > > > Hi, > > > I've been thinking in circles about these aspects of Pythonic design > > and I'm curious what everyone else is doing and thinks. There are 3 > > issues here: > > > 1) 'Declaring' attributes > > There'

Display the results of a query to an html table

2008-08-19 Thread Amie
Hi, how do you display the results of an sql query and display it onto the html form or html table Thanks -- http://mail.python.org/mailman/listinfo/python-list

HTML Tables

2008-08-19 Thread Amie
Hi, Thanks for your help so far. Ok here's a scenario: I have to create a site that displays 34 html tables. In each of these tables the following information has to be displayed: logo (image), site name, date, time. Remember: in all of these 34 tables. the information displayed on each of these t

Re: who to call a list of method inside the class itself

2008-08-19 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: Is the following code is ok. who to call all method. It is working but the call to m() without a reference to self seems strange Thanks for your help class CustomMethod: def method1(self): def method2(self): def method3(self):

who to call a list of method inside the class itself

2008-08-19 Thread maduma
Hi, Is the following code is ok. who to call all method. It is working but the call to m() without a reference to self seems strange Thanks for your help class CustomMethod: def method1(self): def method2(self): def method3(self): def getAll

RE: How to use win32com to convert a MS WORD doc to HTML ?

2008-08-19 Thread Reedick, Andrew
> -Original Message- > From: [EMAIL PROTECTED] [mailto:python- > [EMAIL PROTECTED] On Behalf Of Lave > Sent: Tuesday, August 19, 2008 10:06 AM > To: python-list@python.org > Subject: How to use win32com to convert a MS WORD doc to HTML ? > > Hi, all ! > > I'm a totally newbie huh:) > >

How to use win32com to convert a MS WORD doc to HTML ?

2008-08-19 Thread Lave
Hi, all ! I'm a totally newbie huh:) I want to convert MS WORD docs to HTML, I found python windows extension win32com can make this. But I can't find the method, and I can't find any document helpful. Can anyone help me? Thank in advance. -- http://mail.python.org/mailman/listinfo/python-list

Re: optparse escaping control characters

2008-08-19 Thread Hrvoje Niksic
Dan Halligan <[EMAIL PROTECTED]> writes: > How would I pass a control character to python on the command line? It depends on which command line you are using. Most Unix-like shells will allow you to input a control character by preceding it with ^V. Since \t is the TAB character, you should be a

Re: optparse escaping control characters

2008-08-19 Thread wannymahoots
Thanks for all the responses! -- http://mail.python.org/mailman/listinfo/python-list

Re: ANN: Resolver One 1.2 released

2008-08-19 Thread km
Hi, sounds great - but disappointing to find it only available on window$. Is there any Linux release in near future ??? KM ~~ On Tue, Aug 19, 2008 at 6:10 PM, [EMAIL PROTECTED] < [EMAIL PROTECTED]> wrote: > We are proud to announce the release of R

Re: Getting pid of a remote process

2008-08-19 Thread Miles
On Mon, Aug 18, 2008 at 9:34 AM, srinivasan srinivas wrote: > Could you please suggest me a way to find pid of a process started on a > remote machine by the current process?? If ps + grep (or the more robust tool pgrep) won't work because you're running more than one instance at once, try this:

Re: Question regarding the standard library?

2008-08-19 Thread Hussein B
On Aug 19, 8:10 am, George Sakkis <[EMAIL PROTECTED]> wrote: > On Aug 19, 8:16 am, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > > > > > Hussein B wrote: > > > Is the standard library of Python is compiled (you know, the pyc > > > thing)? > > > Is it allowed to edit the source code of the standard lib

Re: optparse escaping control characters

2008-08-19 Thread Steven D'Aprano
On Tue, 19 Aug 2008 05:35:27 -0700, wannymahoots wrote: > optparse seems to be escaping control characters that I pass as > arguments on the command line. Is this a bug? Am I missing something? > Can this be prevented, or worked around? You are misinterpreting the evidence. Here's the short ex

Re: Question regarding the standard library?

2008-08-19 Thread Fredrik Lundh
Hussein B wrote: Is the standard library compiled? the portions are written in Python are compiled to PYC files, just like modules you write yourself are automatically compiled to PYC files when you import them. (why not just look in the Python installation tree? it's all there for you t

Eggs and Gems

2008-08-19 Thread Hussein B
Hey, Are Python eggs and RubyGems do the same thing (of course Gems is for Ruby and eggs is for Python)? If yes, is it outstanding as the RubyGems? Thanks. -- http://mail.python.org/mailman/listinfo/python-list

View this blogspot

2008-08-19 Thread srinu
http://indianmasalavideos4u.blogspot.com/ -- http://mail.python.org/mailman/listinfo/python-list

View this blogspot

2008-08-19 Thread srinu
http://indianmasalavideos4u.blogspot.com/ -- http://mail.python.org/mailman/listinfo/python-list

Re: searching through a string and pulling characters

2008-08-19 Thread Wojtek Walczak
On Mon, 18 Aug 2008 15:34:12 -0700 (PDT), Alexnb wrote: > Also, on a side-note, does anyone know a very simple dictionary site, that > isn't dictionary.com or yourdictionary.com. This one is my favourite: http://www.lingro.com/ -- Regards, Wojtek Walczak, http://tosh.pl/gminick/ -- http://mail

Re: optparse escaping control characters

2008-08-19 Thread John Machin
On Aug 19, 10:35 pm, [EMAIL PROTECTED] wrote: > optparse seems to be escaping control characters that I pass as > arguments on the command line. Is this a bug? Am I missing > something? Can this be prevented, or worked around? > > This behaviour doesn't occur with non-control characters. > > For

Re: Question regarding the standard library?

2008-08-19 Thread George Sakkis
On Aug 19, 8:16 am, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > Hussein B wrote: > > Is the standard library of Python is compiled (you know, the pyc > > thing)? > > Is it allowed to edit the source code of the standard library? > > I'm not talking about submitting the modified code to Python sourc

Re: Question regarding the standard library?

2008-08-19 Thread Hussein B
On Aug 19, 7:16 am, Fredrik Lundh <[EMAIL PROTECTED]> wrote: > Hussein B wrote: > > Is the standard library of Python is compiled (you know, the pyc > > thing)? > > Is it allowed to edit the source code of the standard library? > > I'm not talking about submitting the modified code to Python source

Re: optparse escaping control characters

2008-08-19 Thread Dan Halligan
On Aug 19, 1:45 pm, Hrvoje Niksic <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] writes: > > optparse seems to be escaping control characters that I pass as > > arguments on the command line.  Is this a bug?  Am I missing > > something?  Can this be prevented, or worked around? > > It has nothing t

Re: optparse escaping control characters

2008-08-19 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: optparse seems to be escaping control characters that I pass as arguments on the command line. Is this a bug? Am I missing something? you're missing the distinction between the content of a string object, and how the corresponding string literal looks. >>> x = {'d

Re: Getting pid of a remote process

2008-08-19 Thread Diez B. Roggisch
srinivasan srinivas wrote: > Thanks a lot. > But i am wondeing will it return correct pid if more than one instance of > run on the remote machine?? Thanks, What do you *think*? How about *trying* that out first? Diez -- http://mail.python.org/mailman/listinfo/python-list

Re: optparse escaping control characters

2008-08-19 Thread Hrvoje Niksic
[EMAIL PROTECTED] writes: > optparse seems to be escaping control characters that I pass as > arguments on the command line. Is this a bug? Am I missing > something? Can this be prevented, or worked around? It has nothing to do with optparse, it's how Python prints strings: $ python -c 'impor

ANN: Resolver One 1.2 released

2008-08-19 Thread [EMAIL PROTECTED]
We are proud to announce the release of Resolver One, version 1.2 - the largest IronPython application in the world, we think, at 38,000 lines of production code backed up by 150,000 lines of unit and functional tests. Resolver One is a Rapid Application Development tool for analysing and presenti

optparse escaping control characters

2008-08-19 Thread wannymahoots
optparse seems to be escaping control characters that I pass as arguments on the command line. Is this a bug? Am I missing something? Can this be prevented, or worked around? This behaviour doesn't occur with non-control characters. For example, if this program (called test.py): from optparse

Re: WindowsXP/ CTypes - How to convert ctypes array to a string?

2008-08-19 Thread dudeja . rajat
On Tue, Aug 19, 2008 at 12:40 PM, <[EMAIL PROTECTED]> wrote: > On Tue, Aug 19, 2008 at 12:20 PM, Fredrik Lundh <[EMAIL PROTECTED]> wrote: >> [EMAIL PROTECTED] wrote: >> >>> I've used CTYPES module to access a function from a dll. This function >>> provides me the version of the dll. This informati

  1   2   >