<?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/2313" />

	<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>2002-08-10T10:58:05-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2002-08-10T10:58:05-04:00</updated>

		<published>2002-08-10T10:58:05-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9597#p9597</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9597#p9597"/>
		<title type="html"><![CDATA[Problem with isnumber]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9597#p9597"><![CDATA[
Thanks... I found that in another post after I had posted that... sorry   <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_sad.gif" width="15" height="15" alt=":(" title="Sad"><p>Statistics: Posted by Guest — Sat Aug 10, 2002 10:58 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[stdragon]]></name></author>
		<updated>2002-08-10T01:49:39-04:00</updated>

		<published>2002-08-10T01:49:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9587#p9587</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9587#p9587"/>
		<title type="html"><![CDATA[Problem with isnumber]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9587#p9587"><![CDATA[
You use isnumber like this:<br><br>if {[isnumber $blah]} {<br>  putlog "it's a number"<br>}<br><br>Might I ask why (or where) you need to get rid of whitespace? If you're getting whitespace in your numbers, then you're extracting them wrong. But anyway, you get rid of whitespace like this (well, it's one way):<br><br>regsub -all " " $blah "" blah<br><br>I think I should point out that [string range] is not the best way to extract words from a string. Also, if you know you're trying to extract 2 numbers, you can use 1 regexp statement to extract and validate both of them.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8">stdragon</a> — Sat Aug 10, 2002 1:49 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2002-08-09T12:35:12-04:00</updated>

		<published>2002-08-09T12:35:12-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9565#p9565</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9565#p9565"/>
		<title type="html"><![CDATA[Problem with isnumber]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9565#p9565"><![CDATA[
Ok, well I figured out that it was putting in whitespace... is there any function that gets rid of whitespace?<p>Statistics: Posted by Guest — Fri Aug 09, 2002 12:35 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2002-08-09T12:05:16-04:00</updated>

		<published>2002-08-09T12:05:16-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9563#p9563</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9563#p9563"/>
		<title type="html"><![CDATA[Problem with isnumber]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9563#p9563"><![CDATA[
It's not a TCL command but it's a function provided by alltools.tcl<br><br>I tried doing it with a $... it still didn't work.<p>Statistics: Posted by Guest — Fri Aug 09, 2002 12:05 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ppslim]]></name></author>
		<updated>2002-08-09T04:55:57-04:00</updated>

		<published>2002-08-09T04:55:57-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9549#p9549</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9549#p9549"/>
		<title type="html"><![CDATA[Problem with isnumber]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9549#p9549"><![CDATA[
isnumber is not a Tcl command, unless it is provided by a tool set or another script.<br><br>Besides that, the way you use the variables in the script is wrong.<br><br>using "isnumber dice" is like asking if the word "dice" is a number. This is clearly faulse, so it returns 0.<br><br>Maybe you are trying to use the variable named "dice". In that case, you should use "isnumber $dice".<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2">ppslim</a> — Fri Aug 09, 2002 4:55 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2002-08-09T02:16:14-04:00</updated>

		<published>2002-08-09T02:16:14-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9547#p9547</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9547#p9547"/>
		<title type="html"><![CDATA[Problem with isnumber]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9547#p9547"><![CDATA[
Well... I was trying to use isnumber but it doesn't seem to work.  I made it echo to the channel to see what it returned and it always returns 0, no matter what.<br><div class="codebox"><p>Code: </p><pre><code>  putmsg $chan "$dice $sides blah[isnumber dice]blah[isnumber sides]blah"</code></pre></div>I put the blahs there to see if I was getting spaces in it.  Howerver, there were no spaces.  Here's the variable assignment.<br><div class="codebox"><p>Code: </p><pre><code>  set dice [string range $text 0 [string wordend $text 0]]  set sides [string range $text [string wordend $text 0] [string wordend $text 1]]</code></pre></div>If anyone can help, it'd be much appreciated.<p>Statistics: Posted by Guest — Fri Aug 09, 2002 2:16 am</p><hr />
]]></content>
	</entry>
	</feed>
