mIRC Home    About    Download    Register    News    Help

Print Thread
#26952 29/05/03 06:08 PM
P
pheonix
pheonix
P
im working on a dialog specially for different themes i create in mirc.
i have a huge icon box to preview the theme in,
this is my preview code
on *:Dialog:theme:dclick:2:{
$findfile($mircdir\themeprevs,$did(2).seltext,1,did -g $dname 1 $nopath($1-))
}
but it doesn't work frown
the theme filenames are all in listbox id 2
any help greatly appreciated smile

#26953 29/05/03 06:17 PM
S
ScatMan
ScatMan
S
on *:Dialog:theme:dclick:2:{
return $findfile($mircdir\themeprevs,$did(2).seltext,1,did -g $dname 1 $1-)
}


#26954 29/05/03 06:21 PM
Joined: Dec 2002
Posts: 698
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 698
Where are the icons? $nopath($1-) means in the main mircdir.
Try also $+(*,$1-,") <- adding "quotes to the file name"

#26955 29/05/03 06:22 PM
P
pheonix
pheonix
P
didnt work:(
$nopath($1-) returns the full directory and $1- returns c:\program confused

#26956 29/05/03 06:25 PM
S
ScatMan
ScatMan
S
on *:Dialog:theme:dclick:2:{
return $findfile($mircdir\themeprevs,$did(2).seltext,1,did -g $dname 1 " $+ $1- $+ ")
}





#26957 29/05/03 06:29 PM
P
pheonix
pheonix
P
thanx works fine grin
thanx to nimue as well smile

#26958 29/05/03 06:53 PM
P
pheonix
pheonix
P
now i got just 1 more question please,

on *:Dialog:theme:sclick:4:{
.disable # $+ * $+ theme
.enable # $+ $replace($did(2).seltext,.bmp,$null)
}

the disable part of that works but enable doesnt, i thought replacing bmp with $null would remove .bmp but it doesnt,
so if anyone can think of another way to remove .bmp then please tell me,
p.s i tried $deltok but that doesnt delete the . frown
thanx in advance for any help

#26959 29/05/03 07:40 PM
Joined: Dec 2002
Posts: 698
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 698
/help $remove

#26960 29/05/03 07:45 PM
S
ScatMan
ScatMan
S
the $replace will work too..

#26961 29/05/03 07:49 PM
Joined: Dec 2002
Posts: 698
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 698
It's rather pointless to replace something with NULL when you can more simply use $remove().

#26962 29/05/03 07:50 PM
P
pheonix
pheonix
P
on *:Dialog:theme:sclick:4:{
.disable # $+ * $+ theme
.enable # $+ $remove($did(2).seltext,.bmp)
}

i looked at help and came up with that^
but it doesnt seem to work either and i dont see a thing wrong with it confused

#26963 29/05/03 07:58 PM
Joined: Dec 2002
Posts: 698
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 698
.enable $eval(#,0) $+ $remove(..)
or
.enable $chr(35) $+ $remove(..)

#26964 29/05/03 08:03 PM
P
pheonix
pheonix
P
both of them returned the same thing confused
* Invalid parameters: $remove (line 25, script4.mrc)

#26965 29/05/03 08:10 PM
Joined: Dec 2002
Posts: 698
N
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 698
.enable $chr(35) $+ $remove($did(2).seltext,.bmp)

#26966 29/05/03 08:15 PM
P
pheonix
pheonix
P
thanx it was just a case of using $chr(35) instead of # smile


Link Copied to Clipboard