mIRC Homepage
Posted By: Div Dialog Checkboxes. How to 'bind' them? - 25/08/05 11:55 AM
Hi all,

Was trying to write a dialog box and wanted to have a checkbox and a button in it.

When I click the button and the checkbox is checked, a command is performed.
When I click the button and the checkbox is NOT checked, another command is performed.

How do I do that? I can get the button to work. I just can't 'bind' the checkbox to it.
Can anyone pls give me a simple example code?

Thanks in advance for all replies.
Posted By: ClickHeRe Re: Dialog Checkboxes. How to 'bind' them? - 25/08/05 12:15 PM
Code:
ON *:DIALOG:name:*:*: {

  if ( $devent == sclick ) {
 
   if ( $did == N ) ;; ID of the checkbox

    if ( $did( $dname, N ).state == 1 ) {
      echo -s checked!
    } 
    else {
      echo -s unchecked!
    }
  }
}
Posted By: Div Re: Dialog Checkboxes. How to 'bind' them? - 25/08/05 02:08 PM
Tnx alot!

Helped me out bigtime...

Do you perhaps also know how I can put a background image on the dialog?
I know that the UPP script offers that. Hence I know its do-able. Just got no clue how smile
Posted By: ClickHeRe Re: Dialog Checkboxes. How to 'bind' them? - 25/08/05 02:09 PM
check with MDX dll
Posted By: MikeChat Re: Dialog Checkboxes. How to 'bind' them? - 25/08/05 06:39 PM
look at the Icon useage in the dialog table
© mIRC Discussion Forums