美文网首页
C#常见报错案例

C#常见报错案例

作者: twoapes | 来源:发表于2018-11-23 11:28 被阅读6次

简介

错误 6702 SA1201: All methods must be placed after all properties.

错误例子

 /// <summary>
 /// 测试委托
 /// </summary>
 private delegate void testDelegate();

 /// <summary>
 /// 测试字段
 /// </summary>
 private bool test = false;

解决方法:字段必须定义在委托之前

 /// <summary>
 /// 测试字段
 /// </summary>
 private bool test = false;

 /// <summary>
 /// 测试委托
 /// </summary>
 private delegate void testDelegate();

相关文章

网友评论

      本文标题:C#常见报错案例

      本文链接:https://www.haomeiwen.com/subject/odwkqqtx.html