在组合框中获得价值 [英] receive value in combobox

查看:68
本文介绍了在组合框中获得价值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我有两个组合框.

我想将combobox1中的数字从1填充到10.

假设comboxbox1 1中的值为1,2,3,10,5,6,7,那么我想在第二个combox框中填充这些值为4,8,9.

我如何在VB.Net应用程序中执行此操作.

Hello to all,

I have two comboboxes.

I want to fill numbers in combobox1 from 1 to 10.

Suppose in comboxbox1 1 have values 1,2,3,10,5,6,7 then I want to fill values in second combox box these are 4,8,9.

How can I do this in a VB.Net application.

推荐答案

我想你是说,您想找到丢失的数字并将其放在组合二中.创建一个数字1-10的列表,然后遍历combo1并删除找到的所有数字.您所需要的清单就是您所需要的.
I THINK you''re saying you want to find the missing numbers and put them in combo two. Create a list, of the numbers 1-10, then iterate over combo1 and remove any numbers you find. The list you have left is what you need.


这是我今天已经读过的关于这个问题的第三个此类问题,因此令我惊讶的是,这是您课程中最新的家庭作业.

很好,您正在学习,但我们不是来做您的作业.

但是,您可能希望考虑一个从1到10的值的数组,并且在将每个值分配给CB1时,会将其标记为第二个数组.

握住那个思想和思想的人,思考吧!
This is the third such question on this subject I have read today, so it strikes me that this is the latest homework task for your course.

It is fine that you are learning, but we are not here to do your homework.

However, you may wish tho think about an array of values from 1 to 10 and as each one is assigned to CB1 it is flagged to a second array.

Hold that thought and think man, think!


这篇关于在组合框中获得价值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆