引用自定义命名控件无效的奇怪问题???
解决方案CTERP_OUT中自定义类库DAL,里面包含文件DataGet.cs,要在界面的后台文件中引用DataGet.cs中的方法,可是我在后台文件中using CTERP_OUT.DAL后并不能找到Dal中的方法,已经确定web文件依赖和引用了dal了, 源码如下,求助!!!
以下为自定义类库:
using System;
using System.Text;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Data.SqlClient;
namespace CTERP_OUT.DAL
{
public class DataGet
{
SqlDataAdapter CmdAdp;
DataTable myTable;
SqlConnection myConnection;
DataSet myDs;
public DataGet()
{
myConnection = new SqlConnection(ConfigurationSettings.AppSettings[ "ConnectionString "]);
CmdAdp = new SqlDataAdapter();
myTable = new DataTable();
myDs = new DataSet();
}
public String Login(String UserId, String PWD)
{
//SqlConnection myConnection = new SqlConnection(ConfigurationSettings.AppSettings[ "ConnectionString "]);
SqlCommand myCommand = new SqlCommand( "ErpLogin ", myConnection);
myCommand.CommandType = CommandType.StoredProcedure;
SqlParameter parameterLoginID = new SqlParameter( "@UserId ", SqlDbType.VarChar, 50);
parameterLoginID.Value = UserId;
myCommand.Parameters.Add(parameterLoginID);
SqlParameter parameterPassword = new SqlParameter( "@PWD ", SqlDbType.VarChar, 50);
parameterPassword.Value = PWD;
myCommand.Parameters.Add(parameterPassword);
SqlParameter parameterReason = new SqlParameter( "@reason ", SqlDbType.VarChar, 50);