say State of ComboBoxGadget

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
User avatar
gurj
Enthusiast
Enthusiast
Posts: 658
Joined: Thu Jan 22, 2009 3:48 am
Location: china
Contact:

say State of ComboBoxGadget

Post by gurj »

say State of ComboBoxGadget
now, pb is:
1) if not use #PB_ComboBox_Editable, EditForm will can't edit, this is ok.
2) if use #PB_ComboBox_Editable and State>-1,EditForm will = Item(State) Until EditForm edited and let them unequal, then State=-1
question: when them equal at State>-1, if Remove Item(State), EditForm will = ""
=============
I think, should:
EditForm always equal Item(-1), if State>-1 and Remove Item(State), EditForm will not changed.

but, must prescribed:
if selected Item of list, must let EditForm's text= Item(State)'s text,
and State will >-1 ,despite EditForm get active.
Until EditForm edited and let them unequal, then State=-1,
and State always=-1, despite EditForm edited and let EditForm's text= Item(lateState)'s text,
Until selected Item of list, then State>-1
my pb for chinese:
http://ataorj.ys168.com
User avatar
gurj
Enthusiast
Enthusiast
Posts: 658
Joined: Thu Jan 22, 2009 3:48 am
Location: china
Contact:

Re: say State of ComboBoxGadget

Post by gurj »

main profit is: GetGadgetText(ComboBoxGadget) always= GetGadgetItemText(ComboBoxGadget,-1)
each State all will is autonomous
my pb for chinese:
http://ataorj.ys168.com
User avatar
gurj
Enthusiast
Enthusiast
Posts: 658
Joined: Thu Jan 22, 2009 3:48 am
Location: china
Contact:

Re: say State of ComboBoxGadget

Post by gurj »

additional: SetGadgetState() always= go selected Item[include -1] of list
if State>-1, then SetGadgetState(ComboBoxGadget,-1), EditForm will not changed.
my pb for chinese:
http://ataorj.ys168.com
User avatar
gurj
Enthusiast
Enthusiast
Posts: 658
Joined: Thu Jan 22, 2009 3:48 am
Location: china
Contact:

Re: say State of ComboBoxGadget

Post by gurj »

AddGadgetItem(ComboBoxG,Item,string)=Insert one newItem before Item[include -1]
'AddGadgetItem()' should change to 'InsertGadgetItem()'
my pb for chinese:
http://ataorj.ys168.com
IdeasVacuum
Always Here
Always Here
Posts: 6425
Joined: Fri Oct 23, 2009 2:33 am
Location: Wales, UK
Contact:

Re: say State of ComboBoxGadget

Post by IdeasVacuum »

Hi gurj

You have put a lot of effort into the description of your request but I find it difficult to understand...... perhaps a working code snippet that reports the gadget state for the different scenarios might help?
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
User avatar
gurj
Enthusiast
Enthusiast
Posts: 658
Joined: Thu Jan 22, 2009 3:48 am
Location: china
Contact:

Re: say State of ComboBoxGadget

Post by gurj »

hi, IdeasVacuum , thanks for your point out !

i think i already say more bad words , i should say a few . :|

thanks you again!
my pb for chinese:
http://ataorj.ys168.com
Post Reply