zoukankan      html  css  js  c++  java
  • 3单元C#练习(重复太多,差别着写)

    3_1.

    重要点:1.改变大小主要在click和size。size要new。

    2.窗体大小显示是在toolStripStatusLable 的text。

    3.新老版本的控件名称差异ToolBarButton——ToolStripMenu,ToolBarPanel——toolStripStatusLable。

    4.窗体的大小也要设置。

    Test3_2

    Backcolor=Color.Blue;    toolStripStatusLabel1.Text = "蓝色";

    Test3_4

     private void toolStripLabel2_Click(object sender, EventArgs e)
            {
                label1.Location = new Point(50, 100);//改变控件Label的位置
               // this.Size = new Size(300, 200);
                //this.toolStripStatusLabel1.Text = "中";
                toolStripStatusLabel1.Text = "中";
            }


     

    test3_9

    private void toolStripLabel1_Click(object sender, EventArgs e)
            {
                this.BackgroundImage = Image.FromFile(@"D:a.jpg");
               // label1.Location = new Point(10, 100);
                //this.Location = new Point(10,100);
                //this.toolStripStatusLabel1.Text = "大";
                toolStripStatusLabel1.Text = "A";
            }

    附加:1.改变鼠标显示    this.Cursor = Cursors.Default;(默认)/WaitCursor;(等待)/Cross;(十字)

    2.右键快捷键:private void Form1_Load(object sender, EventArgs e)
        { 

           this.ContextMenuStrip = this.contextMenuStrip1;

        }

                                    

  • 相关阅读:
    linux卸载rpm包
    Centos6.3手动rpm安装gcc,c++
    阿里云服务器挂载分区
    linux下svn目录管理
    mac搭建cordova的android环境
    mac下搭建cordova开发环境
    程序员除了写代码还可以做点啥
    php之soap使用
    linux中找不到/etc/sysconfig/iptables
    const 位置不一样导致的变化
  • 原文地址:https://www.cnblogs.com/7-58843117/p/7594678.html
Copyright © 2011-2022 走看看