Dear fsmendoza,
Glad to hear that you are making progress! You didn't post your code, but I have a good guess as to what is happening...
My code was a demo, the main purpose of which, was to show you how to "packForget()" and demo what that does. Hide and unhide are for whole windows; pack and packForget are more appropriate for modifying a window that remains on the screen. I put the packForget() code into the subroutine password_reset(). You shouldn't put it there. I did it that way as just a quick demo "hack".
Normally you want the selected option, like password_reset to remain visible to user until he selects another option. Not have it "go away" at the confirmation window and force the user to re-select that option again from the File menu. Maybe the user wants to reset the passwords on multiple accounts? Or perhaps the user wants to work with a window to create multiple accounts?
Re-iterating a few points: You should group the objects for each option into a frame. You will wind up with 3 frames, add, delete, reset. pack and unpack those frames as per the user selection. You can have some variable like "$currently_displayed_option" which has either "nothing" (undef) or a reference to the currently_displayed frame.
When the user selects an option, you want to packForget the currently displayed option (if any). Then display the "new option" that the user selected (of course updating the "$currently_displayed_option").
You are getting "option widget on top of option widget" because the rule that only one or zero options should be displayed at a time is being violated.
Hope this helps.
|