15,175 Topics

Member Avatar for
Member Avatar for stabzagg

Hey guys, I am having some trouble getting my head around tkinter at the moment. I am new to programming and have been using python for about 2 months now. The problem I am having is with RadioButtons. I have a set of radio buttons numbered 1-9 and I can …

Member Avatar for stabzagg
0
297
Member Avatar for dbphydb

Hi, I want to search for a particular text on an html page ---> Build Complete Further execution should be only if the build is successful which is denoted by the text 'Build Complete' on the webpage. Denoted in bold in the code below. [CODE] URL = "http://11.12.13.27:8080/cruisecontrol" from urllib2 …

0
65
Member Avatar for dbphydb

Hi, Please check the below code. [CODE] URL = "http://11.12.13.27:8080/cruisecontrol" from urllib2 import urlopen from HTMLParser import HTMLParser import re # Fetching links using HTMLParser def get_links(url): parser = MyHTMLParser() parser.feed(urlopen(url).read()) parser.close() return parser.links # Build url for Deploy page def get_deploy_url(): url = URL + "/buildresults/xxx_%s_nightly_build" % branch print …

Member Avatar for dbphydb
0
112
Member Avatar for dreadyteddy

Basically need help with one evil section of code! My program opens a start window which introduces the program. A start button leads to a second window with a number of buttons. The main two are "open" and "find restriction site". Im having problem with the code for the latter. …

Member Avatar for dreadyteddy
0
229
Member Avatar for Steven.T

Hi, I need to create a spell checking program where: - the dictionary is loaded in as a set() - the 2nd file is input by the user - all words that are not in the dictionary are added to a list and printed out My code so far is: …

Member Avatar for TrustyTony
0
184
Member Avatar for jl487

Hello, I currently have the following python code: [CODE] #usr/bin/python import os variable=raw_input('Search for this string: ') os.system("grep $variable sample.txt") [/CODE] Basically what I want to do is to grep a string found in the text file "sample.txt" When I run the code, it just hangs. How can I make …

Member Avatar for TrustyTony
0
11K
Member Avatar for dbphydb

Hi, Im basically from QA. I have a piece of code in python that parses HTML pages to reach to a specific link on a webpage. The below code gets me the url of the link which needs to be clicked. What code should i write to simulate clicking a …

Member Avatar for TrustyTony
0
975
Member Avatar for dbphydb

Hi, The below code is doing the following 1. Reading the branch name and the destination from a txt file 2. Parsing thru HTML pages Basically, i want to deploy the build of the branch (supplied thru txt file) on a test environment (supplied thru txt file) The branch_dest file …

Member Avatar for dbphydb
0
205
Member Avatar for gunbuster363
Member Avatar for Lapixx

Hi, I'm new to Python, and although I've quite some programming experience, I wasn't able to find an answer for this problem: As a first project, I am trying to create a small text game. All is going well (since it's very basic), except for my inventory system. At the …

Member Avatar for snippsat
0
8K
Member Avatar for xheavenlyx

Hello everyone, I have searched for this high and low but could not find a solution. To elaborate on the heading. I am trying to figure out a way to do this: 1. I have a text file with one line paths and file listing in it, for example: [CODE] …

Member Avatar for xheavenlyx
0
113
Member Avatar for gabyallheart

I have this program, is working good but i got error when the rows are full because stop and not keep going...can some one help me please..:) import random class Rack(object): def __init__(self, cols, rows): self.rows = rows self.cols = cols grid = Rack(7,6) def returnStartRack(xLen,yLen, blank): grid = [] …

Member Avatar for TrustyTony
0
87
Member Avatar for voolvif

Hi, I'm trying to count the number of unique IP addresses present in an apache log file. I am using a text file to store the unique IP addresses as this needs to scale to large numbers of IP addresses (upwards of 100 million) so using a dictionary or any …

Member Avatar for TrustyTony
0
2K
Member Avatar for Kruptein

Okay my syntax highlighter works very well, I only have on problem, Sometimes GetWords() adds "\n" to operatorless although there isn't pressed an enter I think the problem is within the GetWords() function, but I give all functions to be sure.. Main function is OnKeyUp, colorize prints the text colored …

Member Avatar for Kruptein
0
110
Member Avatar for pythonNerd159

Hey all, I'm currently making a button so that when i click on it, it shows the number of that button in an [B]Entry Screen[/B]. If you can help me it would be great. Thanks again! :) [CODE]def createSeven(self): top=self.winfo_toplevel() top.rowconfigure(0, weight=1) top.columnconfigure(0, weight=1) self.rowconfigure(0, weight=1) self.columnconfigure(0, weight=1) self.Button = …

Member Avatar for Ene Uran
0
85
Member Avatar for sob_andizzle

my assignment is to write a program that asks the user to enter the name of the artist, the name of the art and then how much it is worth. At the end the program should print the average of the values. After that, it wants the program to sort …

Member Avatar for TrustyTony
0
103
Member Avatar for dbphydb

Hi My txt file looks something like this: Branch: ltm_7.4 Destination: Test 5 [CODE] lines = open("branch_dest.txt").readlines() lines=[x.split() for x in lines] print lines branch = "%s" % lines[0][1].strip(': ') print branch destination = "%s" % lines[1][2].strip(': ') print destination [/CODE] I need to extract the branch name and the …

Member Avatar for dbphydb
0
5K
Member Avatar for jpl1993

i'm pretty clueless about everything dealing with python. i need help creating a sorting algorithm that can sort names in a list alphabetically. and example code to help get me started would be much appreciated.

Member Avatar for lllllIllIlllI
0
137
Member Avatar for ktsangop

Hi everybody! I'm facing a really tricky problem in python. I am using the pyserial package to communicate with an external serial interface board. The board accepts certain hexadecimal strings as commands in the following form : --example-- command1 : "\x02\xa1" command2 : "\x03\xa2\xb5" etc... Some of the commands are …

Member Avatar for ktsangop
0
265
Member Avatar for dbphydb

Hi, I want to access a link starting with clients_test on a particular webpage. I have the following code client_re = re.compile(r"clients_test") def get_client_url(): url = get_artifacts_url() for link in get_links(url): if client_re.search(link["href"]): return "http://11.12.13.27:8080" + link["href"] Sometimes the page has many links beginnng with clients_test for e.g: clients_test4, clients_test5, …

Member Avatar for dbphydb
0
116
Member Avatar for TrustyTony

I started to think how to create up and down style loop, and what I ended up was this. Wanted to do it little unconventional way though to demonstrate the property of range as list.[code]for n in range(8): for i in range(n)+range(n-2,-1,-1): print i, print """ Output: 0 0 1 …

Member Avatar for TrustyTony
-1
481
Member Avatar for strider1066

I have registered a new Tkinter module @ pypi. tkPickaColor is a dialog intended for Linux coders to provide a more full featured color chooser than is now available. I say for Linux coders since a better chooser is already available on the MS Windows side. It seems to be …

1
104
Member Avatar for jpl1993

so i have a project due in my computer programming class and i need some serious help. we are learning about recursive sorting, such as merge sort, selection sort, etc. my project has to do with taking 10 people and sorting them in order by their names (alpabetically), rank (numerically), …

Member Avatar for griswolf
0
120
Member Avatar for Jordian

Hey guys, I'm pretty inexperienced with Python, but I wanted to give it a shot because I plan on using it on an upcoming visual aid contest. I've been working on a side scrolling type project where you move left and right and the backgrounds scroll across displaying various images. …

0
84
Member Avatar for ChargrO

Im working on this bit of code below, The only thing im worried about editing atm is the self.toggle() and self.hello(). Im currently getting this error TclError: unknown option "-menu" from this line of code self.config(menu=menubar), does anyone know how i could fix this problem?? [CODE] from Tkinter import * …

Member Avatar for Ene Uran
0
1K
Member Avatar for bbman

Hey everyone, I need some help on some simple Python programming, below is my problem: Identify numbers or words in any .txt file that aren't listed in a provided .txt file and to output those numbers or words that aren't in the text file one per line, in alphabetical or …

Member Avatar for Ene Uran
-1
112
Member Avatar for Qwazil

I'm an absolute beginner. Is there a function to search inside a set? If not, does anyone have a function that does so? (set to search in, value to search for)

Member Avatar for Ene Uran
0
60
Member Avatar for dreadyteddy

I am TRYING to write a program that finds restriction sites in a DNA file and returns a picture and information box of the enzyme which cuts it. My problems are; a) I have no idea if my program works past opening the file directory. b) I dont know how …

Member Avatar for dreadyteddy
0
844
Member Avatar for cchris

I'm in the beginning stages of writing (and learning as I go) a Python database app using SQLite. I have the db structure planned on paper, and I have the queries I'll need in mind, but before I start coding I want to fully test the db design to make …

Member Avatar for griswolf
0
266
Member Avatar for eric_arambula

Hi Guys, I'm a beginner programming with Python. This is my first program. The purpose of this program is to add two numbers and then give me the result. However, after that I want for it to ask me if I want to continue (y) or (n). I came with …

Member Avatar for eric_arambula
0
104

The End.