PS: Because the front leave, not in the time to make a summary, now fill in
If you look at the third chapter, you will find that the third chapter focuses on the design of Windows Forms, including the form background, foreground color, font color, location, and so on.
Because it is a form program, and because the results of test instructions run a variety of, I do not paste the code and run the result diagram.
Below I will simply paste a code, because the latter, although different, but the logic is similar, nothing is different requirements need different methods.
Using System;
Using System.Collections.Generic;
Using System.ComponentModel;
Using System.Data;
Using System.Drawing;
Using System.Linq;
Using System.Text;
Using System.Threading.Tasks;
Using System.Windows.Forms;
Namespace Test3_1
{
public partial class Form1:form
{
Public Form1 ()
{
InitializeComponent ();
}
private void large Toolstripmenuitem1_click (object sender, EventArgs e)
{
This. Size = new System.Drawing.Size (600, 400);
Toolstripstatuslabel1.text = "large form";
}
private void in Toolstripmenuitem1_click (object sender, EventArgs e)
{
This. Size = new System.Drawing.Size (300,200);
Toolstripstatuslabel1.text = "Medium form";
}
private void small Toolstripmenuitem1_click (object sender, EventArgs e)
{
This. Size = new System.Drawing.Size (150, 120);
Toolstripstatuslabel1.text = "small form";
}
private void Button1_Click (object sender, EventArgs e)
{
This. Size = new System.Drawing.Size (600, 400);
Toolstripstatuslabel1.text = "large form";
}
private void Button2_Click (object sender, EventArgs e)
{
This. Size = new System.Drawing.Size (300, 200);
Toolstripstatuslabel1.text = "Medium form";
}
private void Button3_Click (object sender, EventArgs e)
{
This. Size = new System.Drawing.Size (150, 120);
Toolstripstatuslabel1.text = "small form";
}
}
According to test instructions, we need to display the result of the change of the form, which requires a control named Stripstatus.
This control shows the form state in the following ways:
Select this option after you drag the control in.
To implement the menu for test instructions requirements, the process is as follows:
1, locate the control named MenuStrip1, and pull the form into the
Enter your menu name according to its prompts, and then design the submenu according to the test instructions
Specific algorithm, please refer to my above code, I will not post the results of the operation.
C # certification Exam Chapter III