日期:2014-05-18  浏览次数:20408 次

vs2003程序和vs2005程序并存的问题?请大家帮忙
小弟现在接手一个项目,是别人开发的,文档也不全,里面的代码有vs2003和vs2005的,我发现里面有很多程序是被移除在工程之外,如果我全部加进去,好像就报错,这些程序好像就是2003的,如果不放在工程之内的话,一运行,就报这个错:
Description:   An   error   occurred   during   the   parsing   of   a   resource   required   to   service   this   request.   Please   review   the   following   specific   parse   error   details   and   modify   your   source   file   appropriately.  

Parser   Error   Message:   Could   not   load   type   'Public.main '.

Source   Error:  


Line   1:     <%@   Page   language= "c# "   Codebehind= "main.aspx.cs "   AutoEventWireup= "false "   Inherits= "Public.main "   %>
Line   2:     <html>
Line   3:     <head>
 

Source   File:   /web/public/main.aspx         Line:   1  

我查了这个main.aspx.cs存在,名也是正确的。请教各位老大,该如何解决!

------解决方案--------------------
2003
Inherits= "Public.main "
2005
Inherits= "Public_main "
------解决方案--------------------
还有cs文件
2003
using ...;
namespace ×××.Public
{
/// <summary>
/// conect 的摘要说明。
/// </summary>
public partial class main : System.Web.UI.Page
{
protected void Page_Load(object sender, System.EventArgs e)
{
// 在此处放置用户代码以初始化页面
}
}


2005
using ...;


/// <summary>
/// addnews 的摘要说明。
/// </summary>
public partial class Public_main : System.Web.UI.Page

{
protected void Page_Load(object sender, System.EventArgs e)
{
//
}
}
------解决方案--------------------
建议你还是全部转换成Vs2005版本,再修改
------解决方案--------------------
downmoon(邀月) ( ) 信誉:100 2007-08-10 10:14:04 得分: 0


建议你还是全部转换成Vs2005版本,再修改


______________________________
+1