Actually forget the DLL my mistake, i had really forget that, Loki is right, mIRC has this feature by default on dialogs, just put the "test.ico" into your mirc.exe directory and use this code:
To run the dialog:
/dialog -m test test
dialog test {
title "Test Dialog"
size -1 -1 233 121
option dbu
icon test.ico, 0
button "Button", 1, 97 105 37 12
}