@# Quotes DB     useful, funny, interesting





Google
 
Web www.quotesdb.info
Undernet  |  EFnet  |  Quakenet  |  Freenode  |  Dalnet  |  Ircnet  |  Galaxynet
Page: 1 2



Comments:

<0> How can i include a config.tcl file in the main tcl script
<0> if i do it with load i get an error
<0> invalid ELF header
<1> source
<1> source ??
<2> source -> http://Tcl.Tk/man/tcl8.5/TclCmd/source.htm
<0> yeah :D
<0> found it
<3> ;puts \002lala
<2> nick_: #1177 (stdout) lala



<3> ;puts \001lala
<2> nick_: #1178 (stdout) lala
<3> ;puts \013lala
<2> nick_: #1179 (stdout) lala
<3> ;puts \023lala
<2> nick_: #1180 (stdout) lala
<3> ;puts \003lala
<2> nick_: #1181 (stdout) lala
<3> what is underlined again?
<3> ;puts \00314lala
<2> nick_: #1183 (stdout) lala
<3> ;puts \037lala
<2> nick_: #1184 (stdout) lala
<4> i am having problems with string match
<4> here is my code: if {(![string match \[1-9\]* $rest]) && ($rest != "")}
<4> the prob is that "1blah" matches that if just like "10"
<4> what is wrong?
<3> it starts with 1
<3> and you have a *
<3> so it will match anything else
<4> how can i make it match only a number followed by numbers?
<4> and not letters or other characters
<4> i only need it to match 1 through 10 actually
<4> another way (if possible) would be for me to say string match \[1-9\] 0, but a way to say it so that it doesnt matter if there are no occurances of the 0
<3> maybe \[1-9\]+
<3> otherwise look into regexp or maybe scan can do it as well
<4> ok
<4> thanks
<4> ill try that
<4> if {![regexp $rest \[1-9\]?]}
<4> would that work?
<4> sould that work, i should say
<5> or ; string is integer
<5> ;string is integer 1
<2> Robb: #1227 (253 clicks) Tcl: 1
<5> ;string is integer 13234324324234
<2> Robb: #1229 (250 clicks) Tcl: 0



<5> er
<5> ;string is digit 13234324324234
<2> Robb: #1234 (236 clicks) Tcl: 1
<5> use that, do not use regexp unless you really need to
<6> ; string is digit ""
<2> CyBex: #1237 (233 clicks) Tcl: 1
<6> :P
<5> lol
<5> wtf
<6> ; string is digit -strict #""
<2> CyBex: #1241 (216 clicks) Tcl: 0
<5> that cant be right
<6> ; string is digit -strict ""
<2> CyBex: #1243 (231 clicks) Tcl: 0
<6> its in the manual
<5> ;string is digit -string ""
<2> Robb: #1245 (493 clicks) Tcl error: bad option "-string": must be -strict or -failindex
<5> good
<5> ;string is digit -strict ""
<2> Robb: #1247 (215 clicks) Tcl: 0
<5> ;string is digit -strict 0
<2> Robb: #1248 (237 clicks) Tcl: 1
<4> Robb: thanks... what does the -strict do?
<4> works fine without it
<7> ;string is digit ""
<2> [GRiMMY]: #1306 (236 clicks) Tcl: 1
<7> ;string is digit -strict ""
<2> [GRiMMY]: #1307 (240 clicks) Tcl: 0
<5> "If -strict is specified, then an empty string returns 0, otherwise and empty string will return 1 on any cl***."
<4> ah
<4> thanks again ;)
<5> np
<8> you'd think people would read the man page :P
<4> since you brought that up... i dont have a man page
<4> [sysop@linuxhacker pub]$ man tcl
<4> No manual entry for tcl
<4> all i have is the "tcl-commands.doc" that came with my eggdrop
<4> and that doesn't have string is digit
<3> http://tmml.sourceforge.net/doc/tcl/
<4> thanks nick_!
<8> you'd think people would use google... :P
<8> j/k
<4> ;)


Name:

Comments:

Please enter the result of the sum 63 + 46 (to avoid spam):






Return to #tcl
or
Go to some related logs:

#gamedev
+capture localhost traffic +ethereal
#firebird
#flash
#gentoo
#computers
eggdrop ctime
#gamedev
#politics
equivalent of enum in sql server



Home  |  disclaimer  |  contact  |  submit quotes