mIRC Home    About    Download    Register    News    Help

Print Thread
#146410 04/04/06 09:11 AM
Joined: Apr 2006
Posts: 14
O
oneline Offline OP
Pikka bird
OP Offline
Pikka bird
O
Joined: Apr 2006
Posts: 14
Hi, Im trying to make a really long string, possibly up to 10,000 characters in length if possible. In the help file it says binary variables can be any length just depends on memory but when testing it with the following script i get an error:
Code:
alias btest {
  bset -t &test.1 1 $str(e,933)
}

* /bset: line too long
but if i change the second lines $str to $str(e,932) or any lower number i dont get the error. I have 1gb of ram in the box so thats not the problem. If anyone has a recommendedation I would appreciate it, Thanks.

#146411 04/04/06 09:24 AM
Joined: Feb 2004
Posts: 2,019
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
Binvars are indeed virtually unlimited, but what you're facing isn't related to binvars. You're simply trying to pass a string that is too long to an mIRC command (which happens to be /bset here), and in all cases mIRC will return that sort of error. It's no different from: //echo -a $str(a,950)

To illustrate that binvars can hold more data than what normally would be considered a string too long:

//bset -t &a 1 $str(a,930) | bset -t &b 1 $str(b,930) | bcopy &a 931 &b 1 -1 | echo -a $bvar(&a,0)

You'll notice it says that binvar &a contains 1860 bytes of data, which is correct, as I copied the 930 from the second bvar (&b) and concatenated it to the first bvar (&a) which already had 930 bytes of data.


Gone.
#146412 04/04/06 09:40 AM
Joined: Apr 2006
Posts: 14
O
oneline Offline OP
Pikka bird
OP Offline
Pikka bird
O
Joined: Apr 2006
Posts: 14
ahh that makes sense. Thanks.


Link Copied to Clipboard