| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 467 人关注过本帖
标题:求纠正错误
取消只看楼主 加入收藏
叶子512
Rank: 1
等 级:新手上路
帖 子:7
专家分:1
注 册:2012-10-9
结帖率:0
收藏
已结贴  问题点数:20 回复次数:0 
求纠正错误
using System;
using System.Collections.Generic;
using
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace Login
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            String name;
            String password;
            name = textBox1.Text;
            password = textBox2.Text;
            if (textBox1.Text.Equals("Admin") && textBox2.Text.Equals("123456"))
            {
                MessageBox.Show("登录成功!");
            }

            else
            {
                MessageBox.Show("用户或密码不正确! 请核对后重新登录!");
            }
        }

        private void button2_Click(object sender, EventArgs e)
        {
            this.Hide();
        }


        private void radioButton2_CheckedChanged(object sender, EventArgs e)
        {
            if (radioButton2.Checked)
            {
                name.Enabled = true;
                password.Enabled = true;
                textBox1.Enabled = true;
                textBox2.Enabled = true;

            }
            else
           
                name.Enabled = false;
                password.Enabled = false;
                textBox1.Enabled = false;
                textBox2.Enabled = false;

            }
        }
    }
}
  错误: 应输入类型、命名空间定义或文件尾  

搜索更多相关主题的帖子: public private password void 
2012-11-07 15:17
快速回复:求纠正错误
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.041456 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved