mIRC Homepage
Posted By: LO_KEY Spaces, SPAces, I HATE SPACES!! - 24/03/03 07:57 PM
How can i get around worrying about whether or not ppl install there mIRC to a dir with spaces ?

without havn to not let them use spaces

another spaces error im gettin, is if the person usin my file server, sets the trigger to have a root dir that has spaces in it, it messes up the script......

SPACES !!!!!!! GOTO HELL!!!!!!! mad
Posted By: greeny Re: Spaces, SPAces, I HATE SPACES!! - 24/03/03 08:06 PM
use quotes ("c:\program files\mirc") or $shortfn()
Posted By: LO_KEY Re: Spaces, SPAces, I HATE SPACES!! - 24/03/03 08:14 PM
ehhhhhhh

how?

alias read_ini return $readini($mircdirAvalon\Options.ini,$1,$2)

use

alias read_ini return $readini(" $mircdirAvalon\Options.ini ",$1,$2)

instead ?
Posted By: greeny Re: Spaces, SPAces, I HATE SPACES!! - 24/03/03 08:38 PM
try alias read_ini return $readini($+(",$mircdir,Avalon\Options.ini"),$1,$2)
Posted By: LO_KEY Re: Spaces, SPAces, I HATE SPACES!! - 24/03/03 08:48 PM
alias rite_ini return writeini $mircdirAvalon\Options.ini
alias rem_ini return remini $mircdirAvalon\Options.ini

alias rite_ini return writeini ",$mircdirAvalon\Options.ini"
alias rem_ini return remini ",$mircdirAvalon\Options.ini"

and if so, what exactly is that doing?

ok, i changed the three alias's to...

alias read_ini return $readini(" $+ $mircdirAvalon\Options.ini $+ " ,$1,$2)
alias rite_ini return writeini " $+ $mircdirAvalon\Options.ini $+ "
alias rem_ini return remini " $+ $mircdirAvalon\Options.ini $+ "

and it seems to let them change the settings now without prob of it saving what they changed....

Only prob now is that, when sumone type the trigger
and the trigger root dir has spaces in it, it says this for its error....

* /fserve: no such file 'C:\Documents and Settings\Default\Desktop\mIRC\and' (line 1375, Avalon.mrc)

that line in the code is....
fserve $nick 99 $read_ini(Triggers,$replace($1-,$chr(32),&))

in the ini file is...

[Triggers]
testing&t=C:\Documents and Settings\Default\Desktop\Dialogs\

so i dunno how or even where its gettin that dir from ....
Posted By: GBX Re: Spaces, SPAces, I HATE SPACES!! - 24/03/03 09:11 PM
try alias rite_ini return writeini $+(",$mircdir,Avalon\Options.ini")
or alias rite_ini return writeini $shortfn($mircdir $+ Avalon\Options.ini)

you have to use $shortfn
fserve $nick 99 $shortfn($read_ini(Triggers,$replace($1-,$chr(32),&)))
or else again with "
fserve $nick 99 " $+ $read_ini(Triggers,$replace($1-,$chr(32),&)) $+ "
Posted By: LO_KEY Re: Spaces, SPAces, I HATE SPACES!! - 24/03/03 09:58 PM
woooooooho SPACES ARN NO LONGER A THREAT!!!!


thank you so much GBX

What does usin the "" do ?

Posted By: GBX Re: Spaces, SPAces, I HATE SPACES!! - 25/03/03 12:20 AM
the same but with long file names
parameters are separated by spaces, it is impossible for mirc to decide if it is one parameter with a space in it or 2 parameters
so you have to explicitly mark a string as one parameter with "

C:\Program Files\ <= 2 params
"C:\Program Files\" <= 1 param
© mIRC Discussion Forums