mIRC Home    About    Download    Register    News    Help

Print Thread
Page 2 of 2 1 2
Re: want to create an input box for notices #132669 13/10/05 04:39 PM
Joined: May 2005
Posts: 449
bwr30060 Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2005
Posts: 449
I fixed it. It was that problem line:

echo -a $left($gettok($did(1),2,32),-1) $did(2)

I tried changing echo -a to notice. I wasn't sure if the fix would be that simple, but it works. Thanks everyone for the help! laugh

Re: want to create an input box for notices #132670 13/10/05 04:49 PM
Joined: May 2005
Posts: 449
bwr30060 Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2005
Posts: 449
lol, I want to get picky and add one more thing, if I can. Can I make the title of the dialog box "Notice PersonsName"? I saw that the script makes a variable called %nnick, so I tried to put that in the title, but it didnt show up. Any ideas?

Re: want to create an input box for notices #132671 13/10/05 04:59 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
Sorry about that... I was testing it here and forgot to change it back to .notice. I changed it in the post so that anyone else looking at it can use it too.

As for the title:

Stick this into the init section:

dialog -t $dname Notice %nnick

So, the init section will look like:
Code:
on *:dialog:Notice*:init:*: {
  dialog -t $dname Notice %nnick
  did -a $dname 1 Notice %nnick $+ :
  did -ht $dname 3
}

Re: want to create an input box for notices #132672 13/10/05 05:19 PM
Joined: May 2005
Posts: 449
bwr30060 Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2005
Posts: 449
Thanks, that's what I wanted. laugh

Re: want to create an input box for notices #132673 13/10/05 10:00 PM
Joined: May 2005
Posts: 449
bwr30060 Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2005
Posts: 449
Hey,

I know I've been posting alot today, lol, but I'd like to add one more thing. I'd like the dialog box to also have the user's $fulladdress beside the nick. I'm not sure how to get a variable to equal the full address of the selected nick and then put it in the title. The line that sets the variable for the selected nick is:

Code:
  Notice: set %nnick $snick($chan,1) | dialog -m $+(Notice.,%nnick) Notice


Thanks for any help.

Re: want to create an input box for notices #132674 14/10/05 01:51 AM
Joined: May 2005
Posts: 449
bwr30060 Offline OP
Fjord artisan
OP Offline
Fjord artisan
Joined: May 2005
Posts: 449
Never mind the question, lol, I figured it out. I used $address instead of $fulladdress. In case anyone wants to see the finished product, here it is.

Code:
dialog Notice {
  title "Notice" 
  size -1 -1 300 40
  option dbu

  text "",1,5 5 100 8
  edit "",2,5 14 190 10,autohs

  button "Hidden",3,210 50 1 1
  button "Close",4,90 27 20 8,ok
}
on *:dialog:Notice*:init:*: {
  dialog -t $dname NOTICE %nnick %adnick
  did -a $dname 1 Notice %nnick $+ :
  did -ht $dname 3
}
on *:dialog:Notice*:sclick:*: {
  if ($did == 3 && $did(2) != $null) {
    notice $left($gettok($did(1),2,32),-1) $did(2)
    echo -a 4 $left($gettok($did(1),2,32),-1)  $did(2)
    did -r $dname 2
  }
}
menu nicklist {
  -
  Notice: set %nnick $snick($chan,1) | set %adnick $address(%nnick,0) | dialog -m Notice Notice
}

Re: want to create an input box for notices #132675 14/10/05 01:30 PM
Joined: Oct 2004
Posts: 8,327
Riamus2 Offline
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,327
Glad you got it working. I wasn't online at the time. smile


Invision Support
#Invision on irc.irchighway.net
Page 2 of 2 1 2