On May 22, 2008, at 1:44 PM, [EMAIL PROTECTED] wrote:
import Tkinter
With this you call functions from Tkinter as Tkinter.function()
from Tkinter import *
Here you just call function()
i have a program where if i comment out either of those import- statements i get an error. i thought they meant the same thing and from was supposed to be just to imort just a specific function and the * imports everything in the module. but aparently the above statements have diffrent meaning and i cant figure it out fromt he tutorials.
The first creates the Tkinter namespace and all of its functions remain in that namespace. The latter all functions are imported into the local namespace. Cheers Tommy (actually norwegian) -- http://mail.python.org/mailman/listinfo/python-list