<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: TK/TCL HELP in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/tk-tcl-help/m-p/3957477#M65710</link>
    <description>The {} braces around the command prevent $line from being evaluated until the button is pressed.  By that time it has a null value in the context that it is evaluated in.&lt;BR /&gt;  You can use&lt;BR /&gt; -command "puts $line"&lt;BR /&gt;if the $line value is always one word.&lt;BR /&gt;  You can use&lt;BR /&gt; -command [list puts $line]&lt;BR /&gt;to handle lines that are multiple words.  (But it looks like the rest of your example depends on having $line always be one word.)&lt;BR /&gt;The quoting issues with -command are covered in depth in the "Quoting hell" topic at &lt;A href="http://wiki.tcl.tk/1726" target="_blank"&gt;http://wiki.tcl.tk/1726&lt;/A&gt;</description>
    <pubDate>Thu, 08 Mar 2007 15:27:04 GMT</pubDate>
    <dc:creator>Mike Stroyan</dc:creator>
    <dc:date>2007-03-08T15:27:04Z</dc:date>
    <item>
      <title>TK/TCL HELP</title>
      <link>https://community.hpe.com/t5/operating-system-linux/tk-tcl-help/m-p/3957476#M65709</link>
      <description>can someone tell my why the puts is not reflecting the variable?&lt;BR /&gt;&lt;BR /&gt;CUT --&amp;gt;&lt;BR /&gt;&lt;BR /&gt;set fp [open "host2"]&lt;BR /&gt;while {-1 != [gets $fp line]} {&lt;BR /&gt;&lt;BR /&gt;button .a${line} -text "${line} " -width 20 -command {&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;puts $line&lt;BR /&gt;&lt;BR /&gt;}&lt;BR /&gt;&lt;BR /&gt;pack .a${line}&lt;BR /&gt;&lt;BR /&gt;}</description>
      <pubDate>Wed, 07 Mar 2007 11:50:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/tk-tcl-help/m-p/3957476#M65709</guid>
      <dc:creator>hpuxrox</dc:creator>
      <dc:date>2007-03-07T11:50:04Z</dc:date>
    </item>
    <item>
      <title>Re: TK/TCL HELP</title>
      <link>https://community.hpe.com/t5/operating-system-linux/tk-tcl-help/m-p/3957477#M65710</link>
      <description>The {} braces around the command prevent $line from being evaluated until the button is pressed.  By that time it has a null value in the context that it is evaluated in.&lt;BR /&gt;  You can use&lt;BR /&gt; -command "puts $line"&lt;BR /&gt;if the $line value is always one word.&lt;BR /&gt;  You can use&lt;BR /&gt; -command [list puts $line]&lt;BR /&gt;to handle lines that are multiple words.  (But it looks like the rest of your example depends on having $line always be one word.)&lt;BR /&gt;The quoting issues with -command are covered in depth in the "Quoting hell" topic at &lt;A href="http://wiki.tcl.tk/1726" target="_blank"&gt;http://wiki.tcl.tk/1726&lt;/A&gt;</description>
      <pubDate>Thu, 08 Mar 2007 15:27:04 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/tk-tcl-help/m-p/3957477#M65710</guid>
      <dc:creator>Mike Stroyan</dc:creator>
      <dc:date>2007-03-08T15:27:04Z</dc:date>
    </item>
  </channel>
</rss>

