15,190 Topics
![]() | |
Greetings, I've just got 2 python books that are a few years old, they talk about python 2.3. My question is if they would still be useful to learn python? Or if python 2.3 is really that different from 2.6 are they worthless? Thank you. | |
Is there a good way to access browser like IE and run an HTML file from within Python code? | |
Hi everyone, Ive just got a bit of a problem with a program i am currently writing. Basically i have got a csv file with a load of flight info in it, i need to parse that and add it to a dictionary so thati can search through it easily. … | |
i have a file which contains some block of lines like - define host { use linux-box host_name node001 alias node001 address 192.168.36.133 } define host { use linux-box host_name node002 alias node002 address 192.168.73.19 } can anyone help me in getting a script which takes <node001> and <192.168.36.133> as … | |
Hi all, Following is a piece of code which tries to open an image using Tkinter, the root window opens but I am not able to see the image. I don't know what is wrong with my implementation. Could you please have a look at the code & see if … | |
Hi all I am working on a project with Python tk GUI and trying to make a scrollbar that scrolls more than one canvas horizontally tried to approach it as option command = ~~ and ~~ but it seems not working does anyone have any idea on this issue?? | |
Hi, I wrote a program which runs a .bat file using os.system like: 'os.system(pathToBatFile)' and everything was good. Then I decided to turn my program into a service as opposed to being run with the command prompt showing. When my program became a service, I noticed that the os.system command … | |
im making a maths game but i need to know how to make 10 random questions appear in a text box for easy medium and hard addition and subtraction with 1-100 for easy, 1-200 for medium and 1-500 for hard..please help me =) [ICODE]from Tkinter import * import Tkinter as … | |
I'm having a problem which can be exemplified by this python (3) code: [CODE] def askname(): sys.stdout.write("What is your name? ") x = sys.stdin.readline() sys.stdout.write("Hello, "+x) [/CODE] When I run it, I expect to get the prompt, type in my name, and then get the greeting. Instead, it prompts for … | |
not to sure why this does this [code=python] server = smtplib.SMTP("smtp.mail.yahoo.com") server.connect("www.mail.yahoo.com") sendEmail("FlexPt1.txt") Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<stdin>", line 10, in sendEmail File "/usr/lib/python2.5/smtplib.py", line 691, in sendmail self.rset() File "/usr/lib/python2.5/smtplib.py", line 453, in rset return self.docmd("rset") File "/usr/lib/python2.5/smtplib.py", line 378, in … | |
HI, I am working on a project and need to take the sql table structure out using python language. Basic idea behind is to prepare a program which could run on any sql database and table name provided could fetch what are columns and rows present in that table. | |
I've been looking around for the best way to access a frozen exe's stored resources, specifically bitmaps. Apparently this isn't very common or everyone already knows how to do it. I found the pkgutil, am I looking in the right direction? | |
I want to delete a directory through python and the cmd window but i want it to open the command do the rd and then close and continue on with the program with out me having to type RD /s folderName | |
When I try to run the game it freezes and I get an error. the Code: [code] bif = "bg.jpg" mif = "ball.png" import pygame, sys from pygame.locals import * pygame.init() screen = pygame.display.set_mode((800, 600), 0, 32) background = pygame.image.load(bif).covert() mouse_c = pygame.image.load(mif).covert_alpha() while True: for event in pygame.event.get(): if … | |
I've been trying to figure this out for a few days, and my teacher can't really answer my question, as he is just as stumped as I am. Python is supposed to be pass by reference, but I keep getting pass by value when it comes to returning a bool … | |
I am given several coordinates on a 2D plane. These points represent the centers of circles of a constant specified radius. I've been working on a program that outputs all of the coordinates of the circles that collide. This is simple to do if I simply create a distance matrix … | |
I'm wondering if there's a way to open standard I/O as a stream, so I can write and read character by character. Something like [code] handle = open(stdio) [/code] Any ideas? | |
Dear all, I need some help please :) I have been trying to plot several subplots, with the y axis being in linear and the x axis in log. I need both axis to be tight to the data. Here's what I have: [code] import wx import scipy.io.matlab as matlab … | |
Hello, My problem is is that I have an area in the window for an image that is sized relative to that window. I want to place a panel below that image a certain distance from the top based on the height of image after resizing the window occurs(on idle … | |
I have log file which gives CPU utilization and timestamp value at regular interval. Logs snippet below: ==========LOGS============== a:CPU [ 85%]: asdf asd 123 xyz A: Ts 23086, Netvalue 3286, someothervalues 3456 abc abc xyz xyz a:CPU [ 75%]: asdf asd 123 xyz A: Ts 24088, Netvalue 3266, someothervalues 6576 … | |
Hi, I'm trying to use grep on a file from within a python script, I was thinking of something like this: [code] variable = 123 s = subprocess.Popen("grep" + "-w "variable" Data.txt") [/code] How do I use a variable from within the call to grep? Cheers Andy | |
Hey all. this is my first day python programming (been programming java for almost a year tho) and I was trying to put together the classic "shout" method. so far it is like this: [CODE] import time def shout(string): for c in string: print("Gimme a " + c) print(c + … ![]() | |
I am hoping to build a website that accesses a database (possibly Amazon's SimpleDB, but perhaps not) for both presenting query results and adding additional data to the database. I hope to eventually build a sleek AJAX interface as well. I have been told that Python would be an excellent … | |
I have this code: [CODE] import pygame from pygame.locals import * from sys import exit from random import randint from sys import argv from gameobjects.vector2 import Vector2 def Intersect(s1_x, s1_y, s2_x, s2_y, image): if (s1_x > s2_x - image.get_width()): if(s1_x < s2_x + image.get_width()): if(s1_y > s2_y - image.get_height()): if(s1_y … | |
Hey all, Working on a medium sized Tkinter app. I have it working fine, but I feel like the app isn't as clean as I would like it to be, namely because I have a million labels and different widgets and I can't figure out what to call them... For … | |
Don't know how to do it can't find anything online to help :( | |
Hi i can not seem to find out how to put the output of mxmlc file into an output this is wat i have [code=python] os.system("mxmlc.exe swick.swc -output location/swiff.swf")[/code] | |
hi i need a list of command line arguments for flash cs4 | |
Hi All I've seen this topic discussed in various forums, but that was awhile ago and they didn't really answer my questions. I'm looking for a version of py2exe that works with python 3.0.1. As far as I know, there isn't one that has been developed yet. Has one come … | |
![]() | Hey guys and gals, I have a wordpress account and a blog...but I want to start another blog related to Python.. My question is this: is there a widget or anything by means of which any code I post on my blog gets automatically highlighted? Thanks a lot! :) |
The End.