Chad Crabtree | 1 Nov 2004 02:45
Picon
Favicon

Re: Python on handhelds

Anthony P. wrote:

>Hello Everyone,
>
>
>
>I've been asked to develop a simple application that will run on the
>
>Dell Axiom handheld computer. Does anyone know how to get Python to
>
>run on this little device?
>
>
>
>Thanks,
>
>Anthony
>
>_______________________________________________
>
>Tutor maillist  -  Tutor <at> python.org
>
>http://mail.python.org/mailman/listinfo/tutor
>
>
>
>  
>
Looking at things about this I ran over a reference to using jython
on 
(Continue reading)

Chad Crabtree | 1 Nov 2004 03:04
Picon
Favicon

Re: escape-quoting strings

Marilyn Davis wrote:

>I got it!!
>
>This works:
>
>ad0 = address.replace('\\', '\\\\')
>ad0 = ad0.replace('\"','\\"')
>db_style0 = '''%%%s%%''' % ad0
>print "0:", db_style0
>
I thought I should tell you about raw strings  eg.

r'\new'

out puts
\new

not
<newline>
ew

the r at the front automaticly escapes special characters.

		
__________________________________
Do you Yahoo!?
Y! Messenger - Communicate in real time. Download now. 
http://messenger.yahoo.com
_______________________________________________
(Continue reading)

Lloyd Kvam | 1 Nov 2004 04:34
Favicon

Re: escape-quoting strings

On Sun, 2004-10-31 at 18:06, Marilyn Davis wrote:
> I got it!!
> 
> This works:
> 
> ad0 = address.replace('\\', '\\\\')
> ad0 = ad0.replace('\"','\\"')
> db_style0 = '''%%%s%%''' % ad0
> print "0:", db_style0
> 
> On Sun, 31 Oct 2004, Rick Pasotto wrote:
> 
> > On Sun, Oct 31, 2004 at 01:53:42PM -0800, Marilyn Davis wrote:
> > > Hi Python Tutors,
> > > 
> > > I'm having a devil of a time quoting strings properly for MySql.
> > 
> > You example did not include any MySql statements. How are you sending
> > the string to MySql?
> 
> I didn't want to complicate my question with MySql stuff.
> 
> Here is a successful call that depended on the quoting scheme above:
> 
> insert ignore into doorman (in_id,  msg_id, out_address, status, start) values         (60,
"1COOZD-0003KN-2z", "\"Toys \\\"R\\\" Us Gift Card Giveaway\"
<fqgdmvfjfyvjd <at> dlawczhyh.montebic.com>", "NO_MESSAGE", "0")

Your real MySQL code was omitted.  I'll assume a cursor named curs.

(Continue reading)

Marilyn Davis | 1 Nov 2004 06:32

Re: escape-quoting strings


On Sun, 31 Oct 2004, Lloyd Kvam wrote:

> On Sun, 2004-10-31 at 18:06, Marilyn Davis wrote:
> > I got it!!
> > 
> > This works:
> > 
> > ad0 = address.replace('\\', '\\\\')
> > ad0 = ad0.replace('\"','\\"')
> > db_style0 = '''%%%s%%''' % ad0
> > print "0:", db_style0
> > 
> > On Sun, 31 Oct 2004, Rick Pasotto wrote:
> > 
> > > On Sun, Oct 31, 2004 at 01:53:42PM -0800, Marilyn Davis wrote:
> > > > Hi Python Tutors,
> > > > 
> > > > I'm having a devil of a time quoting strings properly for MySql.
> > > 
> > > You example did not include any MySql statements. How are you sending
> > > the string to MySql?
> > 
> > I didn't want to complicate my question with MySql stuff.
> > 
> > Here is a successful call that depended on the quoting scheme above:
> > 
> > insert ignore into doorman (in_id,  msg_id, out_address, status, start) values         (60,
"1COOZD-0003KN-2z", "\"Toys \\\"R\\\" Us Gift Card Giveaway\"
<fqgdmvfjfyvjd <at> dlawczhyh.montebic.com>", "NO_MESSAGE", "0")
(Continue reading)

Lloyd Kvam | 1 Nov 2004 14:54
Favicon

Re: escape-quoting strings

http://python.org/topics/database/

Read the DB-API spec version 2

All of the module documentation assumes you are already familiar with
the DB-API (DBI) and only deals with other issues.  The ability of the
module to map your data into the query becomes critical when dealing
with binary data.

On Mon, 2004-11-01 at 00:32, Marilyn Davis wrote:
> I don't see it in the documentation for MySQLdb at all!  Should I be
> looking somewhere else?
> 
> How did you learn this?
> 
> I wish I knew this a few months ago.  Where have you been?? ;^)
> 
> Marilyn
> 
> > 
> > > 
> > > 
> > > 
> > > Thank you.
> > > 
> > > Marilyn
> > > 
> > > 
> > > _______________________________________________
> > > Tutor maillist  -  Tutor <at> python.org
(Continue reading)

Morgan Meader | 1 Nov 2004 17:33

Re: redundant function ( or, I need advice about cleaning up my code )

Thanks folks,

Great ideas for making my code smaller and more readable. I will use
enumerate() when I need to access more than one list by index. When zip 
and/or oop make more sense to me I will try that definitely.

So many great hints on this list.

Thanks,

Morgan

_______________________________________________
Tutor maillist  -  Tutor <at> python.org
http://mail.python.org/mailman/listinfo/tutor

Michael Lange | 1 Nov 2004 17:49
Picon
Favicon

Re: Does anyone know if IDLE has a maximized setting?

On Fri, 29 Oct 2004 10:50:29 -0500
"Jacob S." <keridee <at> jayco.net> wrote:

> Hello again.
> 
>     I am using IDLE for editing my scripts and I was wondering if there was
> a way to default the IDLE windows to come up maximized every time. As it is,
> I have to maximize the window every time I right click on a file and click
> edit with IDLE. This gets annoying very quickly. Does anyone know what file
> in the idlelib directory might contain the TK script for the editor and
> shell windows so that I might change that setting myself?
> 
>

It's in EditorWindow.py, line 79 (at least my version, the line might vary); the magic line is:

    self.top = top = self.Toplevel(root, menu=self.menubar)

this creates the new window.

You can use the Toplevel's  geometry method to do what you want; simply add a line:

    top.geometry('1024x740+0+0')

this will draw a window of 1024 x 740 pixels into the upper left corner of your screen
(the argument passed to geometry() is generally of the form: 'widthxheight+x-offset+y-offset');
If you don't want to deal too much with the secrets of Tkinter it's probably the easiest to
just try the appropriate values you need.

I hope this helps
(Continue reading)

Eric L. Howard | 1 Nov 2004 18:19

Re: Does anyone know if IDLE has a maximized setting?

At a certain time, now past [Nov.01.2004-05:49:27PM +0100], klappnase <at> freenet.de spake thusly:
> On Fri, 29 Oct 2004 10:50:29 -0500
> "Jacob S." <keridee <at> jayco.net> wrote:
> 
> > Hello again.
> > 
> >     I am using IDLE for editing my scripts and I was wondering if there was
> > a way to default the IDLE windows to come up maximized every time. As it is,
> > I have to maximize the window every time I right click on a file and click
> > edit with IDLE. This gets annoying very quickly. Does anyone know what file
> > in the idlelib directory might contain the TK script for the editor and
> > shell windows so that I might change that setting myself?
> > 
> >
> 
> It's in EditorWindow.py, line 79 (at least my version, the line might vary); the magic line is:
> 
>     self.top = top = self.Toplevel(root, menu=self.menubar)
> 
> this creates the new window.
> 
> You can use the Toplevel's  geometry method to do what you want; simply
> add a line:
> 
>     top.geometry('1024x740+0+0')

I adjust the EditorWindow properties by added the following to
~/.idlerc/config-main.cfg

[EditorWindow]
(Continue reading)

Mr. Dhanvi Kapila | 1 Nov 2004 18:35
Picon

[OT] Part time job openings ?

Hi Guys,
  I am a computer science student doin my masters in Texas A & M
University at Kingsville , TX .
  I was wondering whether anyone know of any part time software / web
development job openings ? I have over 2.5 years exp in India and
would like to earn some extra cash  :)

   Please can anybody forward me any details about any openings or
projects ? i am proficient in PERL, C, C++ , Python, HTML ,
Javascript, DHTML.  I can send my resume on request to interested
parties.

   Awaiting your replies . Thanks

Sincerely,
Dhanvi Kapila
--

-- 
 °v°   kapila * .dhanvi 2.0.0
/(_)\  http://kapiladhanvi.myensim.net
 ^ ^    the good ones may be taken.. but the best are still waiting for me
LinUX powered
_______________________________________________
Tutor maillist  -  Tutor <at> python.org
http://mail.python.org/mailman/listinfo/tutor

Danny Yoo | 1 Nov 2004 18:49
Picon

Re: [OT] Part time job openings ?


On Mon, 1 Nov 2004, Mr. Dhanvi Kapila wrote:

>   I am a computer science student doin my masters in Texas A & M
> University at Kingsville , TX .

[job posting cut]

You're right.  This is completely off topic from helping people learn
about programming Python.  Please use a more relevant forum.  The Python
Job Board:

    http://python.org/Jobs.html

recommends using something like Mojolin:

    http://www.mojolin.com/

_______________________________________________
Tutor maillist  -  Tutor <at> python.org
http://mail.python.org/mailman/listinfo/tutor


Gmane