First, I'd like to thank you for this info! I've been using Perl for quite a while, but being self-taught means that sometimes I have to use "cookbook" code that I don't completely understand. On to my comment/question ...

I tried using the "add_edit_popup" sub in my Tk app. It works great for Tk widgets that are in global scope. I pass into "add_edit_popup" my globally scoped MainWindow along with whatever globally scoped widgets, and it works like a charm!

The problem is when I try to do the same with locally scoped Tk widgets that are in a sub. For example, I have a sub that withdraws the root MainWindow and creates a new MainWindow populated with widgets. When I make a call to "add_edit_popup" from within this sub (passing in the local MainWindow and Entry widgets), I get an error saying something along the lines of "can't call 'menu' without package or object reference".

Is this something anyone can answer from what I've described? If not, I'm happy to cook up some sample code to reproduce this problem.

First time poster but long time researcher here. Thanks so much for any help!


In reply to Re^3: Right-click Edit/Paste in TK Browse Entry by phatWares
in thread Right-click Edit/Paste in TK Browse Entry by ron7

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.