-
Replied To a Post in How to set the value in setLabel function more than once?
It is possible that the GUI or whatever that setLabel uses, does not update the screen until the for loop finishes. We don't have enough info to help much further … -
Replied To a Post in Variable LIST length and output formatting
Tony's question was probably referring to if len(grades) == 1: print ('%s'*len(grades)) % tuple(grades) I would suggest that you test this further, i.e. if len(grades) == 1 then why multiply … -
Began Watching Variable LIST length and output formatting
I'm working with a LIST that am getting from a soup which after the clean up gives me: lists of variable length ['7.0', '7.5', '6.8', '6.9'] or ['7.0', '7.5'] so … -
Replied To a Post in Variable LIST length and output formatting
You will use something similar to the following (but this code is not complete), tutorial for for loop at [Click Here](http://www.zentut.com/python-tutorial/python-for-loop/) explaination of list append and extend at [Click Here](http://www.greenteapress.com/thinkpython/html/thinkpython011.html) … -
Replied To a Post in using or, and byte.find
Print seek_position and see if it is greater than 10. If it is, what happens? Also write a test program using a known string and try different combinations of test_string[start:end] -
Began Watching using or, and byte.find
#!/usr/bin/env python3 import sys import re file = sys.argv[1] f = open(file, 'rb') seek_positoin = 0 artist_string = b'artist=' line = b'' f.seek(seek_positoin) while artist_string.upper() or artist_string.lower() not in line: … -
Replied To a Post in using or, and byte.find
You find the location in the line and then seek in the file using the location found in some unknown line. Choose either the line or the file, for example: … -
Replied To a Post in Tkinter Password with return/enter key (No button) Help!
There is no problem with the entry boxes as the code below will show, i.e. name and password are printed correctly. The problem is verifying the input and "passwords" is … -
Began Watching Tkinter Password with return/enter key (No button) Help!
Ok so I'm trying to make a inter face with a password. my plan is to have a window open up with an input box where you type the password … -
Replied To a Post in Tkinter Password with return/enter key (No button) Help!
There is no way to help someone who doesn't have a clue short of a Vulcan mind meld. But e.focus() there is no widget method "focus" [Click Here](http://effbot.org/tkinterbook/tkinter-events-and-bindings.htm and if … -
Began Watching minimax algorith for reversi
my code tries to generate a tree for reversi/othello but it runs into an infinite while loop and i am unable to debug it.The purpose of this code is to … -
Replied To a Post in minimax algorith for reversi
> it runs into an infinite while loop and i am unable to debug it. Add print statements so you know where it is and what the variables contain. Instead … -
Began Watching Matriz Problem/Connect 4 game
http://pastebin.com/piCzf2sT when put a token in vertical that the main windows is full appear all the line in selected color and not only one, anyone can know why? -
Replied To a Post in Matriz Problem/Connect 4 game
I don't understand the game or what it is supposed to do, but you call clearbotones from c (button press). Shouldn't the color be set in c instead of creating … -
Began Watching Tkinter Digital Clock (Python)
This short Python code gets the local time from the PC as a formatted string using time.strftime('%H:%M:%S'). The time string is displayed in a label using a larger font. A … -
Replied To a Post in Tkinter Digital Clock (Python)
The smallest time displayed is seconds. The function is called every 2/10 of a second, so the clock is not updated if the time to the second has not changed. -
Began Watching How to sort two wxlistctrl
i have this code import wx import datetime,re,os,time,urllib,errno import sys import wx.lib.mixins.listctrl as listmix musicdata = { 0 : ("Bad English", "The Price Of Love", "Rock"), 1 : ("DNA featuring … -
Replied To a Post in How to sort two wxlistctrl
Post a simple example of what you want to do. 276 lines of code is too much as we are trying to guess from your code what you are trying … -
Began Watching How do i go backwards in code to the begining?
So im extremely new to python. Im teaching it to myself for a school project and i heard that calculators are a good place to start so that's exactly what … -
Replied To a Post in How do i go backwards in code to the begining?
"ans" is never changed under the "while ans" loop so it loops continuously. A function [Click Here](http://www.tutorialspoint.com/python/python_functions.htm) would make things easier and cleaner def get_numbers(number_to_get): return_list = [] lits = … -
Began Watching Counting Capital, Lowercase, Digit from text file
no idea why my program is not reading the text file correctly am I doing something wrong, here is what i have so far import string count = 0 infile … -
Replied To a Post in Counting Capital, Lowercase, Digit from text file
> no idea why my program is not reading the text file correctly I have no idea what that means. Print the entire string you are checking and it will … -
Began Watching Help with getting a function to execute continuously
I am working on a simple project and I need a little help. I have created a program that draws circles on a canvas. The circles are blue, and the … -
Replied To a Post in Help with getting a function to execute continuously
I think most programmers will tell you that the Graphics module is more trouble that it is worth. Here is similar with Tkinter and using "after" for the timing. You … -
Began Watching creating graph using pyqt and overlay controls ontop
I havent done this before, but I want to make a window that plots a graph looking at file structure on different server locations, and in that UI I want … -
Replied To a Post in creating graph using pyqt and overlay controls ontop
A simple Google turned up pyQtGraph [Click Here](http://pyqtgraph.org/) and there have to be many other examples out there. Matplotlib is an excellent tool, though not Qt. -
Began Watching Problem with check_button / if statement
Hi, I have been working on some code in Tkinter - this is my first ever coding in python and have basically copied chunks of code over to see what … -
Replied To a Post in Problem with check_button / if statement
You have check_button() declared twice in the code above. One of them should be deleted. A proof of concept to show that the code is working as programmed (although possibly … -
Began Watching [tkinter] update label every n seconds
Heyho users; I need to update a label in a window every x seconds to get an variabel ("res") which is up to date. My current code: def init(win): win.title("Ausgangsposition") … -
Replied To a Post in [tkinter] update label every n seconds
There is more than one way to skin that cat. I use a tkinter variable and update it. Note that you have to call updater() to get the whole thing … -
Began Watching Quick Question about glob.glob
I am working on a python code that is supose to search a directory and see if a file in the directory has a _add_ or a _update_ and to … -
Replied To a Post in Quick Question about glob.glob
You can tell if a file has been changed by the size of the file and date. Check the os.stat module. st_size will give you the size. And one of … -
Replied To a Post in [tkinter]using "destroy()" methode still runs and produces error logs
Keeping track of everything is going to become a pain without a class structure. Note the use of partial to pass the window id to the next function. You can … -
Replied To a Post in [tkinter]using "destroy()" methode still runs and produces error logs
The response was to your first error message. > win" is closed but cmd shows error logs every 5 seconds because of the label in "getcurrentrateandcurrentbalance()". > Any idea how … -
Began Watching [tkinter]using "destroy()" methode still runs and produces error logs
hello daniweb community; The first window my application shows is this one: def init(win): win.title("Ausgangsposition") win.minsize(800, 600) getcurrentrateandcurrentbalance() btn.pack() Usage of win: win = Tk() win = Toplevel() methode getcurrentrateandcurrentbalance() … -
Replied To a Post in [tkinter]using "destroy()" methode still runs and produces error logs
You have to destroy/quit the Tk() instance. You can not do that because "win" now points to a Toplevel. Give the Toplevel another, unique name. win = Tk() win = … -
Began Watching [tkinter] direct user from one window to another
hello daniweb community; After a click on a button I need to "direct" the user from the current window to another, like you may know it from installations ("Yes I … -
Replied To a Post in [tkinter] direct user from one window to another
The button's command parameter http://effbot.org/tkinterbook/button.htm would call a funtion that would open a new Toplevel Gui http://effbot.org/tkinterbook/toplevel.htm -
Began Watching Index error index ort of range
SO im working on a python code that reads a csv file with 1600 entries roughly and i am splitting them up on the collum value of pc numbers. I … -
Replied To a Post in Index error index ort of range
IndexError: list index out of range means that at least one of the items in "x" has less than 3 elements. Before the sort, run some code to print anything … -
Began Watching calling a variable from a function into another function
I have two functions declared in my program, and i want to use the variables in another function to display the matched images. My code is: def messageWindow(): win = … -
Replied To a Post in calling a variable from a function into another function
I don't see the error line in the code you posted either, but in any case in the line im = Image.open(resizelist[val]) resizelist is used to to store images throughout … -
Began Watching Python 3 Question
#### Function secondLoop has the same components with the additional lines # number = len(sentence) while number != 0 #While flag==True letter = input("Enter letter: ") # letter is asked … -
Replied To a Post in Python 3 Question
A guess would be that "newSentence" is used in both loops so contains only the value from the last loop. Or in number = len(sentence) "sentence" is not initialized and … -
Began Watching displaying the values in text box using tkinter
I wanted to display the blue mean value in the text box, but it is giving me an error blue.set(B_mean1) AttributeError: 'numpy.ndarray' object has no attribute 'set' And this is … -
Replied To a Post in displaying the values in text box using tkinter
You use the variable name "blue" in two different places. -
Began Watching tkMessageBox does not appear on application frame
I'm trying to write a program in which a message box is to appear on the application window when the application is launched. The code below produces the message box, … -
Replied To a Post in tkMessageBox does not appear on application frame
Or put it in a Toplevel which can be positioned and sized. -
Replied To a Post in Dictionary from a text file
This gets the directory name and has nothing to do with file name. TKinter has an askopenfilename method to get the file names. -
Replied To a Post in Dictionary from a text file
> but how do I make it more of an arbitrary path (rather than the C:\Users etc) since I need it so that anyone can run that program and write …
The End.