.cs文件编译成.dll文件出错
所用工具vs2005
想把App_Code文件下的两个自定义类:CardUser.cs、CardInfo.cs文件编译成两个dll文件:CardUser.dll、CardInfo.dll,并放在bin目录下.
现在的问题是:CardUser.cs已编译成功为CardUser.dll,可是CardInfo.dll手动编译总是提示如下错误:
e:\card\App_code\CardInfo.cs <56,17> :error CS0246
找不到类型或命名空间名称 "CardUser " <是否缺少using指令性或程序集的引用>
但是我引用了已经。
以下是CardInfo.cs的代码:
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.SqlClient;
using System.Collections.Generic;
using System.Collections;
/// <summary>
/// CardInfo 的摘要说明
/// </summary>
public class CardInfo:System.Web.UI.Page
{
public CardInfo()
{
//
// TODO: 在此处添加构造函数逻辑
//
}
/// <summary>
/// 绑定GridView控件
/// </summary>
/// <param name= "view "> GridView控件名 </param>
/// <param name= "i "> </param>
public void BinderGV(GridView view,int i)
{
string Trans = null;
switch (i)
{
case 1:
Trans = "proc_NOpensCard ";//未开通
break;
case 2:
Trans = "proc_OpensCard ";//已开通
break;
case 3:
Trans = "proc_PayCard ";//充值卡
break;
default:
Trans = "proc_AllCard ";//所有卡
break;