mIRC Home    About    Download    Register    News    Help

Print Thread
#177633 29/05/07 12:33 AM
H
harl91
harl91
H
Code:
dialog dns {

  title "DNS/IP"
  size 300 200 95 50
  option dbu

  text "Enter IP (default is %bot.ip)" , 1, 10 10 75 7
  edit "", 2, 10 17 75 10
  button "Enter", 3, 10 27 75 10

}


how do i get %bot.ip to be treated like a variable and not real txt?

Joined: Sep 2005
Posts: 2,630
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,630
Change the text in the dialog's init event:

Code:
dialog dns {

  title "DNS/IP"
  size 300 200 95 50
  option dbu

  text "" , 1, 10 10 75 7
  edit "", 2, 10 17 75 10
  button "Enter", 3, 10 27 75 10

}
on *:dialog:dns:init:*:{ did -a dns 1 Enter IP (default is %bot.ip $+ ) }

Joined: Oct 2004
Posts: 8,061
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Oct 2004
Posts: 8,061
Or, just remove the quotes around the text. The danger of that is a comma (and perhaps other characters) cannot be displayed without quotes. If you know you won't have commas or any other characters that may cause it to not work, then you don't need to worry about it.

Code:
text Enter IP (default is %bot.ip $+ ) , 1, 10 10 75 7


Link Copied to Clipboard