为列表框成员分配值 [英] Assigning values to listbox members
问题描述
你好
我正在为winforms工作,最近我一直在问一些基本的问题。
所以我的问题是我有2个表格(mainform,add_valueform)。在我的主表单中我有一个ListBox whihc有以下meberes(工资,储蓄)这个列表框叫做listbox1,还有一个Button也调用按钮1,最后是一个名为sumBox.Now的文本框,当用户调出一个列表框成员并按下mainform按钮时,add_valueForm打开,并且在add_value形式中只有一个文本框,用户输入的值应该是整数,我想要要分配给该特定列表框成员的值。我可以启动一个表格等,但我找不到将值分配给列表框成员的方法。
我希望你们理解。
非常感谢
Hello
I am working on winforms and lately i have been asking some basic questions so bare with me.
So my question is i have 2 forms(mainform, add_valueform).In my main form i have a ListBox whihc has following meberes(salary,savings) this listbox is called listbox1, there is a Button also called button 1 and lastly a textbox called sumBox.Now when user slects a listbox member and press the button the of the mainform, add_valueForm opens and in add_value form there is just one textbox in which user enters a value which should be integer now i want that value to be assigned to that particular listbox member. I can launch a form etc but i cannot find a way to assign the value to listbox member.
I hope you guys understand.
thanks anyways
推荐答案
我过去的回答应该会给你一个想法:combobox.selectedvalue在winform中显示{} [ ^ ]。
如果你仍然没有得到它,请问一些后续问题,我会回答。
-SA
My past answer should give you the idea: combobox.selectedvalue shows {} in winform[^].
If you still did not get it, please ask some follow-up questions, I'll answer.
—SA
这篇关于为列表框成员分配值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!