904 Posted Topics

Member Avatar for hema dhevi.N

[B][COLOR="Red"]If you know a good project, please post it here. If you have questions, start your own thread and don't clutter the sticky.[/COLOR][/B]

Member Avatar for hema dhevi.N
-3
107
Member Avatar for Masood_786

Please use code tags with your code to preserve the indentations. Otherwise the code is very difficult to read and not too many folks will help. [noparse][code][/noparse] your Python code here [noparse][/code][/noparse]

Member Avatar for Masood_786
0
716
Member Avatar for Enorym

Try to write your code files and run them from the IDE that comes with the Python installation (called IDLE). The IDE will connect the working directory (where your code file is located) with Python.exe See [url]http://www.daniweb.com/forums/thread20774.html[/url]

Member Avatar for Enorym
0
149
Member Avatar for CharlieNewey

Something like this? [code]# plot of log line from tkinter import * import math def particleCount(decay, p0, time): p = (p0*math.e)**(-(decay*time)) return (p) # define root window root = Tk() root.title("Radioactive Decay Graph") # create frame to put control buttons onto frame = Frame(root, bg='grey', width=400, height=40) frame.pack(fill='x') button1 = …

Member Avatar for CharlieNewey
0
5K
Member Avatar for Ashena

Use matplot from: [url]http://sourceforge.net/projects/matplotlib/files/matplotlib/[/url] You can modify the example from: [url]http://matplotlib.sourceforge.net/examples/api/barchart_demo.html[/url]

Member Avatar for Ashena
0
413
Member Avatar for vbx_wx

Polymorphism --- Behavior of an "object" is determined at run-time and depends on what kind/type of object it is: [code] # for instance x * y x = 2; y = 3; print x * y # 6 # but ... x = 'A'; y = 3; print x * …

Member Avatar for bumsfeld
0
74
Member Avatar for Tommymac501

Which version of Windows are you using? PyQT 4.8 seems to work better with Windows7 than Windows XP

Member Avatar for Tommymac501
0
2K
Member Avatar for Thropian

You can also do string slicing: [code]s = 'hello' print(s[:1]) # h # more print(s[:2]) # he print(s[:4]) # hell [/code]

Member Avatar for Thropian
0
282
Member Avatar for Narue
Member Avatar for bumsfeld
6
257
Member Avatar for vik.singh

You can design rather simple calculator using the Python function eval(): [code]# simple calculator using Python function eval() # improvements: # safeguard eval(), error check math expression # loop for more calculations and so on # # importing math functions allows you to enter sin(1.6), pi etc. from math import …

Member Avatar for bumsfeld
0
154
Member Avatar for Zemfik
Member Avatar for happygeek
Member Avatar for Chatterbox721
0
758
Member Avatar for christina>you

Cheney was a professional draft dodger. [url]http://en.wikipedia.org/wiki/Dick_Cheney[/url] Bush's dad got GW into the Texas National Guard Airforce. I understand he didn't even show up for the required physicals. However, he did fly around in the US.

Member Avatar for Future_Dictator
0
1K
Member Avatar for G-Do

Thanks G-do for informing us over the interesting medical work you are doing! Orange sounds like Python based data mining module, things that should be explored. Slovenia is just like Austria, very nice with much history and great people.

Member Avatar for Gael Varoquaux
0
332
Member Avatar for BestJewSinceJC

I just love "Frazier", particularly Eddie the dog, Daphne Moon and Niles.

Member Avatar for SgtMe
1
305
Member Avatar for b_bayaraa_d

What happens if you run this test code: [code=python]#!/usr/bin/env python # example frame.py # http://www.pygtk.org/pygtk2tutorial/sec-Frames.html import pygtk pygtk.require('2.0') import gtk class FrameExample: def __init__(self): # create new window window = gtk.Window(gtk.WINDOW_TOPLEVEL) window.set_title("Frame Example") # connect "destroy" event to signal handler window.connect("destroy", lambda w: gtk.main_quit()) window.set_size_request(300, 300) # set border width …

Member Avatar for nikosokin
0
298
Member Avatar for cwarn23
Member Avatar for Avner .H.

I always learn that the use of global variables is to be discouraged. Is this the only way to copy static variable behaviour in Python?

Member Avatar for zaghaghi
0
9K
Member Avatar for vmars

Now I see, you want to avoid flood of email from DaniWeb. You can: 1 Follow jlm699 advice 2 Try your Python skills and write small program to UNsubscribe you. :)

Member Avatar for Stefano Mtangoo
0
398
Member Avatar for freddypyther

There is Boa Constructor (similar to Delphi) that uses wxPython as the GUI toolkit (you need wxPython isstalled first), free download from: [url]http://downloads.sourceforge.net/boa-constructor/boa-constructor-0.4.4.win32.exe[/url] There is also wxGlade, just frame builder/designer, also using wxPython: [url]http://wxglade.sourceforge.net/[/url]

Member Avatar for brandonrunyon
0
987
Member Avatar for shadwickman

Let's hope the file _cpyHook.pyd was compiled with the proper MS C version to match the Python2.6 exe file.

Member Avatar for bujisky
0
613
Member Avatar for SpS
Member Avatar for Sodabread
0
193
Member Avatar for indianscorpion2

Interesting code. Corrected a few errors, now it works. However fact(14) is less then fact(13).

Member Avatar for Adak
0
176
Member Avatar for terence193

[QUOTE]Dear Dad, $chool i$ really great. I am making lot$ of friend$ and $tudying very hard. With all my $tuff, I $imply can`t think of anything I need. $o if you would like, you can ju$t $end me a card, a$ I would love to hear from you. Love, Your …

Member Avatar for vegaseat
0
885
Member Avatar for jrcagle
Member Avatar for pythonista
0
141
Member Avatar for lllllIllIlllI

I am using SPE, it's okay, it incorporates wxGlade (GUI builder) and the excellent WinPdb (debugger), but it does not have some features like code completion. I use mostly PyScripter, it is written with Delphi, and has the features I want. It's a standalone .exe file that works on Windows. …

Member Avatar for Tommymac501
0
821
Member Avatar for Stefano Mtangoo

The Open Graphics Library (OGL) is now well integrated with wxPython, but to go from there to something that works like VPython you need lots of work: [code=python]import wx import wx.lib.ogl as ogl class MyFrame(wx.Frame): def __init__(self): wx.Frame.__init__( self, None, wx.ID_ANY, title="explore wx.lib.ogl", size=(400,300)) canvas = ogl.ShapeCanvas(self) canvas.SetBackgroundColour("yellow") diagram = …

Member Avatar for isabel puchoc
0
433
Member Avatar for vmanes
Member Avatar for sureronald

As performance is concerned, the file read from disk will be the slowest part by far!

Member Avatar for mahesham
0
4K
Member Avatar for masterofpuppets

If you are curious, also check this out: [url]http://www.daniweb.com/code/snippet216539.html[/url]

Member Avatar for TrustyTony
0
798
Member Avatar for xav.vijay

Could be different level of XP upgrade. Early version of Window XP quite buggy!

Member Avatar for luizfeliperj
0
919
Member Avatar for Ancient Dragon

Bush is poor excuse for President, but yet 20% of voters still support him. Probably the same 20% that will support Sara Palin, fraud or not. No sense to argue any further.

Member Avatar for johnnybgood
0
450
Member Avatar for G_S

The only example I could find was this one ... [code]''' Python31 includes the Tkinter Tile extension Ttk. Ttk comes with 17 widgets, 11 of which already exist in Tkinter: Button, Checkbutton, Entry, Frame, Label, LabelFrame, Menubutton, PanedWindow, Radiobutton, Scale and Scrollbar The 6 new widget classes are: Combobox, Notebook, …

Member Avatar for G_S
0
9K
Member Avatar for nezbo

You can use the class instance as key: [code]class RedKey(pygame.sprite.Sprite): image = None count = 0 def __init__(self, location): pygame.sprite.Sprite.__init__(self) if self.image is None: self.image = pygame.image.load("red_key.png").convert_alpha() if self.count > 0: self.rect = self.image.get_rect() self.rect.topleft = location # more of your code here ... location = ... # pick your …

Member Avatar for nezbo
0
198
Member Avatar for gsmoura
Member Avatar for BestJewSinceJC
Member Avatar for avatar103
0
659
Member Avatar for jephthah

Here I thought that cow tipping was stepping on a cow's output and tipping in the process.

Member Avatar for vegaseat
4
189
Member Avatar for Rashakil Fol
Member Avatar for Dave Sinkula

[QUOTE=Dave Sinkula;532558][url=http://www.redstate.com/files/obama-che.jpg]Obama campaign HQ in Texas[/url][/QUOTE]This Fox News fake has Karl written all over it. He is working for them now. I guess Obama should have had this picture on the wall:

Member Avatar for jephthah
0
6K
Member Avatar for HiHe

Need gadget that makes the sun shine at night when we would need the light.

Member Avatar for Lardmeister
0
147
Member Avatar for nonemsludo

Pretty wild coding with a little bit of Ruby thrown in! Here is just one small hint using actual Python code: [code]def get_vowels(word): number_vowels = 0 for c in word: if c in 'aeiouy': number_vowels += 1 return number_vowels def get_consonants(word): number_consonants = 0 for c in word: if c …

Member Avatar for nonemsludo
-1
462
Member Avatar for The Dude
Member Avatar for The Dude
0
291
Member Avatar for HiHe

In Python3 input() will give you string. You can use eval(input()) to get numbers, but I would make sure that the string you are using with eval() does not contain any nasty commands.

Member Avatar for TrustyTony
0
4K
Member Avatar for ioiinc

[QUOTE=ioiinc;1198251]I would like to know if anyone knows the date that asselin.com was aquired by Hover. Also, who started asselin.com and where would I go to find out this information. Thanks, Jerry W. IOI, Inc.[/QUOTE]Are you looking for work?

Member Avatar for KenJackson
-6
96
Member Avatar for lllllIllIlllI

At least your posts contain substance. Got this error when I posted the above: Fatal error: Allowed memory size of 16777216 bytes exhausted (tried to allocate 4864 bytes) in /home/daniweb/httpdocs/forums/includes/class_bbcode.php(172) : eval()'d code on line 66

Member Avatar for bumsfeld
10
248
Member Avatar for Salem
Member Avatar for bumsfeld
1
78
Member Avatar for toll_booth

If you have a Windows machine and Python26, simply download and install: PIL-1.1.7.win32-py2.6.exe

Member Avatar for toll_booth
0
206
Member Avatar for lmnopt
Member Avatar for kenji

Here you go: [code]# tested with Python 3.1.1 import fractions a = 10 b = 25 cd = fractions.gcd(a, b) sf = "the greatest common divisor of the integers %d and %d is %d" print( sf % (a, b, cd) ) """my result the greatest common divisor of the integers …

Member Avatar for kenji
0
184
Member Avatar for adam321

So, what is the effort on your part? See: [url]http://www.daniweb.com/forums/announcement114-2.html[/url]

Member Avatar for adam321
-2
198

The End.