[Tutor] MONEY MATTERS

2007-03-21 Thread Kirk Bailey
ok, SHOULD THIS BE A THREAD OR A SEPERATE LIST? Many of ius are independants, and write code for the love of it- or to promote and sell independantly. So possibly a thread discussing ways to turn useful code into moiney is a useful idea. If the wish of the list is a thread here, we can do tha

Re: [Tutor] Making table

2007-03-21 Thread Kent Johnson
Alan Gauld wrote: > others have discussed format strings. > One final tip is to put the format string in a variable then use that > in printing/writing the output > > eg: > > fmt = '%10.3f\t%10.3f\t%10.3f' > print fmt % v1,v2,v3 > > This has the advantage that you can build the format string > d

Re: [Tutor] pywin DoModal vs CreateWindow

2007-03-21 Thread Alan Gauld
"Ben" <[EMAIL PROTECTED]> wrote > Recently my friend ask me for help on pywin32 gui programming. pywin32 is only really a sensible route if you already know MFC and want to translate some design into Python. Otherwise its painful. Mainlybecause the underlying windows code is painful. It is full

Re: [Tutor] Making table

2007-03-21 Thread Alan Gauld
"Per Jr. Greisen" <[EMAIL PROTECTED]> wrote > I need to generate a table with different x,y,z values and write > them to a > file: > 10.171 -15.243 -2.558 > 9.837 -14.511 -1.923 > -23.451 -13.870 51.507 > others have discussed format strings. One final tip is to put the format string in a va

Re: [Tutor] File locking

2007-03-21 Thread Alan Gauld
Jeff, Just catching up after a week on vacation, but nobody seems to have picked this up so... > I'm always disappointed when I find something that Python > doesn't handle in a platform independent way. That's often because the platforms all do it too differently! :-) > 1. I don't see a way to

Re: [Tutor] threading and gui programming

2007-03-21 Thread Alan Gauld
"Ben" <[EMAIL PROTECTED]> wrote > What really confuses > me is that there are so many gui programming options for python > (i.e. > pywin32, wxPython, etc). Is this means that all of these available > gui > options be able to integrate with threading? Thanks. Yes, they all have the concept of a

Re: [Tutor] Making table

2007-03-21 Thread Carroll, Barry
> -Original Message- > Date: Tue, 20 Mar 2007 22:53:15 +0100 > From: J?nos Juh?sz <[EMAIL PROTECTED]> > Subject: Re: [Tutor] Making table > To: tutor@python.org > Message-ID: >[EMAIL PROTECTED]> > Content-Type: text/plain; charset="iso-8859-2" > > Dear Barry, > > >>Using a formatt

[Tutor] pywin DoModal vs CreateWindow

2007-03-21 Thread Ben
Recently my friend ask me for help on pywin32 gui programming. There is one thing that throw us off (Note. Both of us don't have any mfc background and we are newbie in python). When the "DoModal" is called, the gui will stay in loop. It is different when the "CreateWindow" is called. If we run th

[Tutor] help me and ill love u!!! :)

2007-03-21 Thread p l
hello tutor! im a new python programmer and iv been given a task to get as much details that i can on my system memory... now, i have allready found how to get the total physical memory and the avalible memory.. iv also found how to get the virtual mem and a few more stuff... but now im stuck!!

Re: [Tutor] "from X import Y" vs "import X"

2007-03-21 Thread Kent Johnson
[EMAIL PROTECTED] wrote: > Hi list, > > In Python books one can read that "from X import Y" is > better than "import X", but some times (IMO) it is not. What book is that? I'm not aware of any general reason to prefer one of these forms over another. "from X import *" is discouraged. > > for eg

Re: [Tutor] "from X import Y" vs "import X"

2007-03-21 Thread Rikard Bosnjakovic
On 3/21/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > my actual question is "is this a rare case related to the > scipy distribution, or something general in python" The first. I've never ever stumbled on an error like yours, and I use from FOO import BAR alot without any whole module-impor

[Tutor] "from X import Y" vs "import X"

2007-03-21 Thread emilia12
Hi list, In Python books one can read that "from X import Y" is better than "import X", but some times (IMO) it is not. for eg. in SciPy, from numpy import matrix from scipy.linalg import inv, det, eig A=matrix([[1,1,1],[4,4,3],[7,8,5]]) print det(A) crashes with : RuntimeError: module compiled

Re: [Tutor] Should I use python for parsing text

2007-03-21 Thread Kent Johnson
Jay Mutter III wrote: > "Jay Mutter III" > wrote > >>/ See example// //next:/ >>/ A.-C. Manufacturing Company. (See Sebastian, A. A.,/ >>/ and Capes, assignors.)/ >>/.../ >>/Aaron, Solomon E., Boston, Mass. Pliers. No. 1,329,155 ;/ >>/Jan. 27 ; v. 2