in reply to perl tk get user input

Maybe not using MainLoop at all works? See tk close window and the replies, which suggest that using $dialog->Show() works for showing a dialog.

Replies are listed 'Best First'.
Re^2: perl tk get user input
by vinoth.ree (Monsignor) on Jul 04, 2019 at 10:06 UTC

    But, I am able to destroy the window, but the control is not coming back to the calling function.


    All is well. I learn by answering your questions...

      Maybe you are properly leaving the MainLoop, but Tk does not want to restart it? I don't know. I think the better approach is to not start the MainLoop at all.