Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Toplevel problem

Status
Not open for further replies.

coffeysm

MIS
Oct 7, 2004
571
US
I am trying to create a pop window that would ask someone to change a user's password. It displays everything, however, the problem is it displays it on the root window "." I would like it to display on the new window that pops up when the button is clicked. Anyone have any suggestions?

Code:
proc change_password {} {

    global passwd passwd2
    toplevel .passwd
    label .lpasswd -text "Enter New Password:"
    entry .epasswd -textvar passwd
    label .lpasswd2 -text "Re-enter New Password:"
    entry .epasswd2 -textvar passwd2
    button .exit -text "Exit" -command { destroy .passwd }
    pack .lpasswd .epasswd .lpasswd2 .epasswd2 .exit

}

button .change_pw -text "Change Password" -command { change_password }
pack .change_pw
 
Nevermind I am an idiot, LOL. I forgot to add the name of the toplevel window to each widget....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top