popups.dll help

August 26 2007 at 3:12 AM
No score for this post
  (no login)
from IP address 72.36.194.106

 

I can't seem to figure out how to use a right click event in a dialog to activate the popup.. here is the code I am working on:

dialog acro {
title "Viewing: Acronyms Module"
size -1 -1 123 65
option dbu
list 1, 1 3 120 60
check "Enable Acronyms module.", 2, 2 55 75 10
}

on *:dialog:acro:*:*:{
var %32 = $dname, %48 = dll $rty(popups.dll)
var %1 = acro.txt, %2 = 1
if ($devent = init) {
mdx SetMircVersion $version
mdx MarkDialog $dname
mdx SetControlMDX $dname 1 Listview report showsel rowselect sortascending droptarget grid> $vmdx
mdx SetFont $dname 1,2 -10 400 Tahoma

did -i $dname 1 1 headerdims 100 135
did -i $dname 1 1 headertext $+(Input, ,Output)

while (%2 <= $lines(%1)) {
did -a $dname 1 $+($gettok($read(%1,%2),1,32), ,$gettok($read(%1,%2),2-,32)) | inc %2
}
}
if ($devent = $sclick) {
if ($did = 1) {
if ($gettok($did(%32,1,1),1,32) == rclick) {
var %5 = $$input(Enter shortcut here:,o,Shortcut:), %3 = $$input(Enter output here:,o,Output:), %4 = LoadImg pop.up icon small system\icons\ $+ $1 | var %xel.1 $icondir($1-)
%48 New pop.up 16 16
%48 %4 add.ico
%48 SetStyle pop.up bordericon
%48 AddItem pop.up +D 3 Add $cr addacro %5 %3
%48 AddItem pop.up +> Remove
tokenize 32 $dll(system\dll\popup,dll,Popup,pop.up)
}
}
}
}


alias addacro {
set %xel.oti 1
set %xel.seline.acro $did(acro,1).sel
write acro.txt $+($1, ,$2-)
}

-

I'm sure there are many other errors, but right now I really need to get this up and running. Thank you in advance. =)

 
Scoring disabled. You must be logged in to score posts.Respond to this message   
Create your own forum at Network54
 Copyright © 1999-2009 Network54. All rights reserved.   Terms of Use   Privacy Statement