<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/20331" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2017-04-23T13:39:15-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/20331</id>

		<entry>
		<author><name><![CDATA[juanamores]]></name></author>
		<updated>2017-04-23T13:39:15-04:00</updated>

		<published>2017-04-23T13:39:15-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106183#p106183</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106183#p106183"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106183#p106183"><![CDATA[
<blockquote class="uncited"><div><blockquote class="uncited"><div>As I mentioned before, BoT does not respond to <strong class="text-strong">\t</strong> <br>...</div></blockquote>Try it with a space before and after the \t .<br><br>I seem to remember that is what I had to do.</div></blockquote>I have tried what you advised me and it does not work, the BoT ignores the \t is as if they did not exist, nor does it give error.<br><br>The tabulator (\ t) assume them as simple white spaces<div class="codebox"><p>Code: </p><pre><code>foreach pair $results {     scan $pair {%s%d} name rank     incr rr     if {$rr == 1} { putmsg $canal_owners "\002\0034 \t $rr. \t $name \t $rank"}     if {$rr == 2} { putmsg $canal_owners "\0032 \t $rr. \t $name \t $rank"}     if {($rr != 1) &amp;&amp; ($rr != 2) &amp;&amp; ($rr &lt;= 5)} { putmsg $canal_owners "\0031 \t $rr. \t $name \t $rank"}     if {$rr &gt; 5} {continue}   } </code></pre></div>Result:<blockquote class="uncited"><div> 1. Maria 12<br> 2. Jose 10<br> 3. Ana 9<br> 4. Pedro 7<br> 5. Luis 3</div></blockquote>Here's what I want to get, regardless of the length in characters of the nicks that precede the score:<br><img src="http://i64.tinypic.com/fbhz75.png" class="postimage" alt="Image"><br>As you see, the units go under the units and the tens under the tens, and ordinal numbers and names are also aligned in the corresponding column.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12499">juanamores</a> — Sun Apr 23, 2017 1:39 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[willyw]]></name></author>
		<updated>2017-04-22T09:20:20-04:00</updated>

		<published>2017-04-22T09:20:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106176#p106176</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106176#p106176"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106176#p106176"><![CDATA[
<blockquote class="uncited"><div>As I mentioned before, BoT does not respond to <strong class="text-strong">\t</strong> <br>...</div></blockquote>Try it with a space before and after the \t .<br><br>I seem to remember that is what I had to do.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10420">willyw</a> — Sat Apr 22, 2017 9:20 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[juanamores]]></name></author>
		<updated>2017-04-22T05:37:07-04:00</updated>

		<published>2017-04-22T05:37:07-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106174#p106174</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106174#p106174"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106174#p106174"><![CDATA[
As I mentioned before, BoT does not respond to <strong class="text-strong">\t</strong> <br>I do not know if it's because of the eggdrop version I use or because the librarys are old. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_confused.gif" width="15" height="15" alt=":?" title="Confused"> <br><br>I tried to update the libraries, but when recompiling I did not work parts of my codes.<br>I also tried to update the eggdrop to the latest version, but I do not recognize the ascii characters (BoT symbols).<br>Now I will open a new thread for this.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12499">juanamores</a> — Sat Apr 22, 2017 5:37 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2017-04-21T02:32:48-04:00</updated>

		<published>2017-04-21T02:32:48-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106159#p106159</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106159#p106159"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106159#p106159"><![CDATA[
It should work with the <em class="text-italics">\t</em><div class="codebox"><p>Code: </p><pre><code>% foreach line $result { scan $line {%s%s} name rank; puts "$name \t$rank" }bla     123moo     23</code></pre></div>like I said first time.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Fri Apr 21, 2017 2:32 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[juanamores]]></name></author>
		<updated>2017-04-20T13:01:22-04:00</updated>

		<published>2017-04-20T13:01:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106158#p106158</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106158#p106158"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106158#p106158"><![CDATA[
I replaced the <em class="text-italics">putmsg</em> with  for the <em class="text-italics">puthelp "PRIVMSG...</em> and the results are still not tabulated.<br>If you look at the result that you have shared, you will see that the numbers are not aligned.<br><br>I want the point (numbers) to all begin in the same column, regardless of the number of characters in the name.<br><strong class="text-strong">EDIT</strong>: View this image created with an excel sheet<br><img src="http://i64.tinypic.com/fbhz75.png" class="postimage" alt="Image"><br>That's what I want to get with the tcl code.<br>It's possible?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12499">juanamores</a> — Thu Apr 20, 2017 1:01 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2017-04-20T12:14:12-04:00</updated>

		<published>2017-04-20T12:14:12-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106157#p106157</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106157#p106157"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106157#p106157"><![CDATA[
I take it this is from the <a href="http://forum.egghelp.org/viewtopic.php?t=20326" class="postlink">Sort file data</a> code so i got the same code I posted and instead of what you posted above I used:<div class="codebox"><p>Code: </p><pre><code>foreach pair $results { incr xscan $pair {%s%d} name rankputhelp "PRIVMSG $chan :$x. $name $rank"}</code></pre></div>And the result is:<blockquote class="uncited"><div>[19:35] &lt;@cez&gt; !avgs<br>[19:35] &lt;@bot&gt; 1. Maria 12<br>[19:35] &lt;@bot&gt; 2. Jose 10<br>[19:35] &lt;@bot&gt; 3. Ana 9<br>[19:35] &lt;@bot&gt; 4. Pedro 7<br>[19:35] &lt;@bot&gt; 5. Luis 3</div></blockquote>I even used your code with a small change to post into the current channel:<div class="codebox"><p>Code: </p><pre><code>foreach pair $results {scan $pair {%s%d} name rankincr rrif {$rr == 1} { puthelp "PRIVMSG $chan :\002\0034 $rr. $name  $rank"}if {$rr == 2} { puthelp "PRIVMSG $chan :\0032 $rr. $name $rank"}if {($rr != 1) &amp;&amp; ($rr != 2) &amp;&amp; ($rr &lt;= 5)} { puthelp "PRIVMSG $chan :\0031 $rr. $name $rank"}if {$rr &gt; 5} {continue}} </code></pre></div>and the output is also ok:<blockquote class="uncited"><div>[19:41] &lt;@cez&gt; !avgs<br>[19:41] &lt;@bot&gt; 1. Maria 12<br>[19:41] &lt;@bot&gt; 2. Jose 10<br>[19:41] &lt;@bot&gt; 3. Ana 9<br>[19:41] &lt;@bot&gt; 4. Pedro 7<br>[19:41] &lt;@bot&gt; 5. Luis 3</div></blockquote>with only difference that first line is with red.<br><br>Are you sure isn't something with your irc client displaying info wrong or perhaps something wrong with your <em class="text-italics">putmsg</em> function?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Thu Apr 20, 2017 12:14 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[juanamores]]></name></author>
		<updated>2017-04-20T11:44:40-04:00</updated>

		<published>2017-04-20T11:44:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106156#p106156</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106156#p106156"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106156#p106156"><![CDATA[
This I had already tried but it did not work for me.<br>What I want is that the names and points are aligned in the same column.<br>I can not put an example here, because I do not see the tool to tabulate the forum.<br>With the code that I shared you above it out like this:<blockquote class="uncited"><div>1. Ana 12<br>2. Federico 11<br>3. Pedro 9<br>4. Manuel 5<br>5. The_best_of_the_world 2</div></blockquote>If I use \t as the example:<div class="codebox"><p>Code: </p><pre><code>$var1\t$var2\t$var3</code></pre></div>Result:<blockquote class="uncited"><div>1.Ana12<br>2.Federico11<br>3.Pedro9<br>4.Manuel5<br>5.The_best_of_the_world2</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12499">juanamores</a> — Thu Apr 20, 2017 11:44 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2017-04-20T00:36:34-04:00</updated>

		<published>2017-04-20T00:36:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106154#p106154</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106154#p106154"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106154#p106154"><![CDATA[
What do you mean by in the same column? Give an example.<br><br>Edit: If you want to have a TAB between the results then make the line like:<div class="codebox"><p>Code: </p><pre><code>$var1\t$var2\t$var3</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Thu Apr 20, 2017 12:36 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[juanamores]]></name></author>
		<updated>2017-04-19T17:36:10-04:00</updated>

		<published>2017-04-19T17:36:10-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=106153#p106153</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=106153#p106153"/>
		<title type="html"><![CDATA[Tabulations]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=106153#p106153"><![CDATA[
How can I tabulate the rr,name and rank variables so that they are all in the same column?<div class="codebox"><p>Code: </p><pre><code>foreach pair $results {  scan $pair {%s%d} name rank   incr rr  if {$rr == 1} { putmsg $chan_owners "\002\0034 $rr. $name  $rank"}  if {$rr == 2} { putmsg $chan_owners "\0032 $rr. $name $rank"}  if {($rr != 1) &amp;&amp; ($rr != 2) &amp;&amp; ($rr &lt;= 5)} { putmsg $chan_owners "\0031 $rr. $name $rank"}  if {$rr &gt; 5} {continue}} </code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12499">juanamores</a> — Wed Apr 19, 2017 5:36 pm</p><hr />
]]></content>
	</entry>
	</feed>
