mIRC Home    About    Download    Register    News    Help

Print Thread
#148651 09/05/06 06:28 AM
Joined: May 2006
Posts: 122
J
jizzy Offline OP
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2006
Posts: 122
Is it possible to add some text to the edit part of a combobox without adding it to the list?


If only women came with popup menus and online help.
#148652 09/05/06 02:07 PM
Joined: Oct 2005
Posts: 1,741
G
Hoopy frood
Offline
Hoopy frood
G
Joined: Oct 2005
Posts: 1,741
Quote:
You can access the edit control in a combobox by using 0 as the N value.


/help /did

I don't know if that adds the data to the edit box or not.

-genius_at_work

#148653 09/05/06 02:47 PM
Joined: May 2006
Posts: 25
A
Ameglian cow
Offline
Ameglian cow
A
Joined: May 2006
Posts: 25
Quote:
You can access the edit control in a combobox by using 0 as the N value.


Have you tried something like that?

Code:
/did -a $dname id 0 Blablabla


==================
Abstraction is art.
#148654 10/05/06 01:45 AM
Joined: May 2006
Posts: 122
J
jizzy Offline OP
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2006
Posts: 122
That only work with $did.
//echo $did($dname,$did,0)


If only women came with popup menus and online help.
#148655 10/05/06 03:57 AM
Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
I think it makes a difference if you use -i or -a or whatever
try this
Code:
alias combo dialog -m combo combo
dialog combo {
  title "Combo Box Test"
  size -1 -1 150 100
  option dbu
  combo 100, 10 10 130 50
  edit "", 200, 10 60 130 10
  button "Insert", 900, 50 75 50 10
}
on *:dialog:combo:init:0:{ did -f combo 200 }
on *:dialog:combo:sclick:900:{ did -ri combo 100 0 $did(combo,200) }

#148656 10/05/06 08:24 AM
Joined: May 2006
Posts: 122
J
jizzy Offline OP
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2006
Posts: 122
I was actally talking about a combo box with the edit flag

combo 2, 10 15 110 10, edit, drop


If only women came with popup menus and online help.
#148657 10/05/06 10:04 AM
Joined: May 2006
Posts: 25
A
Ameglian cow
Offline
Ameglian cow
A
Joined: May 2006
Posts: 25
Don't know where is the problem? I've just tried the line of code I wrote you before, and it works. I don't mean the $did identifier, but command /did.


==================
Abstraction is art.
#148658 10/05/06 02:40 PM
Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
Quote:
I was actally talking about a combo box with the edit flag
combo 2, 10 15 110 10, edit, drop


change it to -k
test
Code:
alias combo dialog -dm combo combo
dialog combo {
  title "Combo Box Test"
  size -1 -1 150 100
  option dbu
  combo 2, 10 10 130 50, edit drop
  edit "Type Here", 200, 10 60 130 10, center
  button "CLICK", 900, 50 75 50 10
}
on *:dialog:combo:init:0:{
  var %i = 1
  while (%i <= 4) { 
    did -a combo 2 $r(a,z)
    inc %i
  }
  did -f combo 200
}
on *:dialog:combo:sclick:900:{ did -ik combo 2 0 $did(combo,200) }

#148659 11/05/06 08:43 AM
Joined: May 2006
Posts: 122
J
jizzy Offline OP
Vogon poet
OP Offline
Vogon poet
J
Joined: May 2006
Posts: 122
Cheers, but I found an easier way. Just thought I could shorten my code.
Code:
did -c $dname id $findtok($didtok($dname,id,44),selection-name-here,1,44)


If only women came with popup menus and online help.

Link Copied to Clipboard