Welcome![Sign In][Sign Up]
Location:
Search - mfc combo B

Search list

[GUI DevelopComboBox

Description: 这是MFC中一个关于组合框的简单例子,有助于学习简单的MFC编程。-This is a MFC combo box on a simple example will help to learn MFC programming simple.
Platform: | Size: 1879040 | Author: huangyaqin | Hits:

[Othermfc_button

Description: 1.建立一个基于Dialog的MFC工程; 2.设置在Dialog窗体宽度为500,在其第一行位置放置一个组合框和一个按钮; 3.组合框设置8个默认选项,选项的内容分别是数字1,2,3,4,5,6,7,8 4.组合框允许输入数字,范围是0-50 5.按钮标题是“Do it” 6.点击“Do it”按钮,实现功能:①根据组合框填写或选择的数值(假设该值是n),创建n个按钮,每个按钮的大小都是高25长40,从界面上第二行开始显示,每一行显示的按钮数不超过(10-行号),超过时自动显示到下一行(其中行号从0开始);②每个创建的按钮标题是按钮的序号,即0,1,2…n-1,按钮的背景颜色和文本颜色都是随机值;③但点击创建的按钮时,在Dialog窗口的标题显示该按钮相关的信息,包括标题内容,背景颜色值,文本颜色值(其中颜色以字符串"RGB(r,g,b)"格式,r,g,b分别代表颜色的红绿蓝分量)。 -(1) Establish a Dialog-based MFC project (2) set the width of the Dialog form 500 in its first line location to place a combo box and a button 3 combo box set eight default option, option is the number 1, 2, 3, 4, 5, 6, 7, 8 Combo box allows you to enter numbers, range 0-50 5 button title is "Do it." Click the "Do it" button, the realization of functions: (1) complete or selected value of a combo box (the value is assumed to n), to create the n button, the size of each button are 25 long 40, from the interface first the two lines begin to show, each row shows the number of buttons does not exceed (10- line number) over automatically to the next line (line number starting from 0) ② each created button title is the serial number of the button, that is, 0 , 1,2 ... n-1, the button s background color and text color are random values​ ​ ③ Click Create button, the button-related information, including the title content, the value of the background color, text is displayed
Platform: | Size: 4367360 | Author: 事实上 | Hits:

CodeBus www.codebus.net