Re: [Tutor] PYFTDI Library for FT232H

2012-08-03 Thread Mark Lawrence
On 03/08/2012 02:02, Steven D'Aprano wrote: On 03/08/12 09:38, John Battle wrote: I am relatively new to Pyton and am trying to use a library called pyftdi which is used to establish communication with USB chips made by FTDI. I have been able to install the library and write a simple piece of co

[Tutor] adding a windows registry value

2012-08-03 Thread Albert-Jan Roskam
Hi,   I am trying to change a registry value (Windows 7, Python 2.7) but it won't work when I try to do this using Python:   import os # 1 using this from Python won't work, but double-clicking the file works. os.system(r"regedit /s C:\Users\Desktop\set_temp.reg") # 2: using this from Python won'

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Steven D'Aprano
On 04/08/12 00:39, Albert-Jan Roskam wrote: Hi, I am trying to change a registry value (Windows 7, Python 2.7) but it won't work when I try to do this using Python: Define "won't work". Does it: - change the registry entry, but no effect is apparent? - raise an exception? - crash? - silently

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Alan Gauld
On 03/08/12 15:39, Albert-Jan Roskam wrote: ...Is there a built-in way to do this (I don't have win32api)? Yes you do, because ctypes is part of the standard Python library. And ctypes lets you access Win32api. See: http://docs.python.org/library/ctypes.html#module-ctypes for examples. As t

[Tutor] Creating a basic CGI script

2012-08-03 Thread Smaran Harihar
Hi, I wish to create a basic cgi script which will interact with the ajax call from my Ext-JS, modify it and then return it back to the ext-js. I just completed this tutorial which tells me how I should create a cgi-script but it was interacting with the py script. How do I make a simple cgi for

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Kwpolska
Anyone has an idea why this list wants me to send mail to the OP rather than the ML itself? Anyways, On Fri, Aug 3, 2012 at 4:39 PM, Albert-Jan Roskam wrote: > Hi, > > I am trying to change a registry value (Windows 7, Python 2.7) but it won't > work when I try to do this using Python: > > impor

Re: [Tutor] Creating a basic CGI script

2012-08-03 Thread Alan Gauld
On 03/08/12 17:58, Smaran Harihar wrote: I wish to create a basic cgi script which will interact with the ajax call from my Ext-JS, modify it and then return it back to the ext-js. This forum is for people learning the Python language and the standard library. CGI is a standard module but not

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Alan Gauld
On 03/08/12 18:42, Kwpolska wrote: Anyone has an idea why this list wants me to send mail to the OP rather than the ML itself? Anyways, The list doesn't care, you probably did it by hitting Reply instead of Reply All. Reply replies to the person who posted. Reply All replies to all on the lis

[Tutor] Newline question

2012-08-03 Thread Alexander Q.
I'm following the tutorial from python.org ( http://docs.python.org/tutorial/introduction.html) and am having a few indiscrepancies regarding the new line command. The tutorial says that this code hello = "This is a rather long string containing\n\ several lines of text just as you would do in C.

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Walter Prins
On 3 August 2012 19:35, Alan Gauld wrote: > The list doesn't care, you probably did it by hitting Reply > instead of Reply All. > > Reply replies to the person who posted. Reply All replies to all > on the list. Just like regular email. > That's just how its set up, to mimic normal email. Well n

Re: [Tutor] Newline question

2012-08-03 Thread Jerry Hill
On Fri, Aug 3, 2012 at 4:18 PM, Alexander Q. wrote: > I'm following the tutorial from python.org > (http://docs.python.org/tutorial/introduction.html) and am having a few > indiscrepancies regarding the new line command. > > The tutorial says that this code > > hello = "This is a rather long strin

Re: [Tutor] adding a windows registry value

2012-08-03 Thread eryksun
On Fri, Aug 3, 2012 at 10:39 AM, Albert-Jan Roskam wrote: > Hi, > > I am trying to change a registry value (Windows 7, Python 2.7) but it won't > work when I try to do this using Python: > > import os > # 1 using this from Python won't work, but double-clicking the file works. > os.system(r"regedi

Re: [Tutor] Newline question

2012-08-03 Thread Alexander Q.
On Fri, Aug 3, 2012 at 1:40 PM, Jerry Hill wrote: > On Fri, Aug 3, 2012 at 4:18 PM, Alexander Q. wrote: > > I'm following the tutorial from python.org > > (http://docs.python.org/tutorial/introduction.html) and am having a few > > indiscrepancies regarding the new line command. > > > > The tutor

Re: [Tutor] Newline question

2012-08-03 Thread Alan Gauld
On 03/08/12 22:09, Alexander Q. wrote: That was it Jerry- when I typed in "print hello" instead of just "hello", the output was exactly like the one in the tutorial. Yes, the interactive interpreter shows the representation (repr()) of the data while print shows the normal output. There are s

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Alan Gauld
On 03/08/12 21:32, Walter Prins wrote: Well normally I expect emails from a list (being the direct sender), But there is no concept of 'direct sender' in email. All emails bounce around the internet via innumerable mail relays before arriving. The only thing email protocols care about is the

Re: [Tutor] adding a windows registry value

2012-08-03 Thread eryksun
On Fri, Aug 3, 2012 at 6:28 PM, Alan Gauld wrote: > > The problem with the reply goes to list approach is that replying to a > poster individually becomes very tedious - you have to manually remove the > unwanted addresses. > > Of course the best solution is to have a client that recognises lists

[Tutor] I-Phone App in Python?

2012-08-03 Thread Fred G
I just googled whether it is possible to write an i-phone app in Python and got very confusing, and not super good results. Is it possible? And if so, what module(s) do I need to install? Much thanks! ___ Tutor maillist - Tutor@python.org To unsubscri

Re: [Tutor] adding a windows registry value

2012-08-03 Thread eryksun
On Fri, Aug 3, 2012 at 10:39 AM, Albert-Jan Roskam wrote: > > import os > # 1 using this from Python won't work, but double-clicking the file works. > os.system(r"regedit /s C:\Users\Desktop\set_temp.reg") Do you have a user named Desktop, or was this supposed to be "C:\Users\USER_NAME\Desktop\se

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Steven D'Aprano
On 04/08/12 06:32, Walter Prins wrote: On 3 August 2012 19:35, Alan Gauld wrote: The list doesn't care, you probably did it by hitting Reply instead of Reply All. Reply replies to the person who posted. Reply All replies to all on the list. Just like regular email. That's just how its set u

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Ramchandra Apte
You can use the _winreg module. I posted this message earlier but I replied to OP, not replied to all. On 4 August 2012 08:00, Steven D'Aprano wrote: > On 04/08/12 06:32, Walter Prins wrote: > >> On 3 August 2012 19:35, Alan >> Gauld> >> wrote: >>

Re: [Tutor] adding a windows registry value

2012-08-03 Thread Ramchandra Apte
I was the first person to respond actually. On 4 August 2012 08:50, Ramchandra Apte wrote: > You can use the _winreg > module. > I posted this message earlier but I replied to OP, not replied to all. > > > On 4 August 2012 08:00, Steven D'Aprano wr

Re: [Tutor] Newline question

2012-08-03 Thread Alexander Q.
On Fri, Aug 3, 2012 at 2:09 PM, Alexander Q. wrote: > > > On Fri, Aug 3, 2012 at 1:40 PM, Jerry Hill wrote: > >> On Fri, Aug 3, 2012 at 4:18 PM, Alexander Q. >> wrote: >> > I'm following the tutorial from python.org >> > (http://docs.python.org/tutorial/introduction.html) and am having a few >>