| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 5545 人关注过本帖
标题:没有找到适合的方法来重写
只看楼主 加入收藏
huiger8723
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2011-4-12
结帖率:0
收藏
已结贴  问题点数:20 回复次数:3 
没有找到适合的方法来重写
namespace WindowsFormsApplication2
{
    partial class Form1
    {
        /// <summary>
        /// 必需的设计器变量。
        /// </summary>
        private components = null;

        /// <summary>
        /// 清理所有正在使用的资源。
        /// </summary>
        /// <param name="disposing">如果应释放托管资源,为 true;否则为 false。</param>
       protected override void Dispose(bool disposing)
        {
            if (disposing && (components != null))
            {
                components.Dispose();
            }
            base.Dispose(disposing);
        }

        #region Windows 窗体设计器生成的代码

        /// <summary>
        /// 设计器支持所需的方法 - 不要
        /// 使用代码编辑器修改此方法的内容。
        /// </summary>
        private void InitializeComponent()
        {
            this.button1 = new System.Windows.Forms.Button();
            this.SuspendLayout();
            //
            // button1
            //
            this.button1.Location = new System.Drawing.Point(248, 131);
            this.button1.Name = "button1";
            this.button1.Size = new System.Drawing.Size(97, 37);
            this.button1.TabIndex = 0;
            this.button1.Text = "button1";
            this.button1.UseVisualStyleBackColor = true;
            this.button1.Click += new System.EventHandler(this.button1_Click);
            //
            // Form1
            //
            this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
            this.ClientSize = new System.Drawing.Size(542, 414);
            this.Controls.Add(this.button1);
            this.Name = "Form1";
            this.Text = "Form1";
            this.Load += new System.EventHandler(this.Form1_Load);
            this.ResumeLayout(false);

        }

        #endregion

        private System.Windows.Forms.Button button1;
    }
}

标记的地方
错误:“WindowsFormsApplication2.Form1.Dispose(bool)”;没有找到适合的方式来重写



[ 本帖最后由 huiger8723 于 2011-4-12 11:35 编辑 ]
搜索更多相关主题的帖子: null false 
2011-04-12 11:34
hainandgm
Rank: 6Rank: 6
等 级:侠之大者
威 望:3
帖 子:111
专家分:475
注 册:2007-6-21
收藏
得分:10 
你看一下Form1.cs的namespace是为"WindowsFormsApplication2",如果不是,改回来就可以了
2011-04-13 08:56
hainandgm
Rank: 6Rank: 6
等 级:侠之大者
威 望:3
帖 子:111
专家分:475
注 册:2007-6-21
收藏
得分:0 
你看一下Form1.cs的namespace是否为"WindowsFormsApplication2",如果不是,改回来就可以了
2011-04-13 08:57
a101069
Rank: 2
等 级:论坛游民
帖 子:18
专家分:64
注 册:2011-4-10
收藏
得分:10 
我没看到有虚方法或者是抽象方法哦~
2011-04-13 22:22
快速回复:没有找到适合的方法来重写
数据加载中...
 
   



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

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