根据组合框选择填充编辑框 [英] populate editboxes depending on combobox selection

查看:59
本文介绍了根据组合框选择填充编辑框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用MFC vc ++基于对话框的应用程序。

在我的对话框中我假设3个组合框有3个字符串和9个editcontrol



c1 .... E11 E21 E31

c2 .... E12 E22 E32

c3 ..... E13 E23 E33



每当我从组合框''c1'中选择a字符串时,它应该将E11 E21 E31字段值分别填充为abc,bcd,edc,对于c2和c3分别相同但不同的字符串值应该填充。我知道哪个编辑框的字符串。

我怎么能这样做?提前谢谢..

I am using MFC vc++ dialogbased application.
on my dialog i have supposed 3 comboboxs with 3 strings and 9 editcontrol
such as
c1.... E11 E21 E31
c2 .... E12 E22 E32
c3..... E13 E23 E33

Whenever i have select "a" string from combo box ''c1'' it should populate E11 E21 E31 field value as "abc, bcd, edc" respectively same for c2 and c3 but diffrent strings values should populate. I know which string for which editboxs.
How I can do it? Thank you in advance..

推荐答案

查看此链接 [ ^ ]如何使用MFC中的ComboBox控件。一步一步的教程。
Check this link [^]on how to use ComboBox control in MFC. A step by step tutorial.


处理组合框上的更改事件,并对其作出反应。很基本的东西。你为什么在2013年成为MFC的初学者?人们还在使用MFC和C ++吗? C#更好。
Handle the change event on the combo box, and react to it. Pretty basic stuff. Why are you a beginner in MFC, in 2013 ? Do people still use MFC and C++ ? C# is way better.


这篇关于根据组合框选择填充编辑框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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