Click here to Skip to main content
15,900,815 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
HEllo Team,

I am getting the error as follow:
SQL
Error   2'QBPO.Application.Bpo.DataManagers.QBpoDataManager'
does not contain a definition for 'UpdateQCProcessed'
 and no extension method 'UpdateQCProcessed' accepting a first argument
of type 'QBPO.Application.Bpo.DataManagers.QBpoDataManager' could be found
 (are you missing a using directive or an assembly reference?)


as i have added the .dll in references and Namespace in the .cs file.
Then also i am getting the error .Kindly help.
Pls find the code
public Result Add(IEntityBase entityBase)
{
Result result = null;
try
{
IUserEntity userEntity = entityBase as IUserEntity;
Logger.Write("Inside BpoManagerWrite.Add()", LogType.Information);
QBpoDataManager bpoDataManager = new QBpoDataManager();
OcrDataManager ocrDataManager = new OcrDataManager();
result = new Result();
ICustomerLoanData customerLoanData = QBpoEntityCreator.GetCustomerLoanDataEntity();
using (TransactionScope transactionScope = new TransactionScope(TransactionScopeOption.Required, CommonUtility.GetRequireTransactionOptions()))
{
if(userEntity.Role == QBPOUserRole.QbpoQcUser.ToString())
{
bpoDataManager.Update(entityBase);
bpoDataManager.UpdateQCProcessed(entityBase);
}
else
{
////Add in LoanDataTable
bpoDataManager.Add(entityBase);
////Update in OCRLoan Tbl Table.Processed= 1, updated by =1 , updated date = Now
ocrDataManager.Update(entityBase);
}
transactionScope.Complete();
}

Logger.Write("Exiting BpoManagerWrite.Add()", LogType.Information);
}
catch (Exception exception)
{
exception.HandleException(Global.CONSTSTREXCPOLICYBUSINESS);
result.AddError("Technical Error occured. Please contact to system administrator");
}

return result;
}
and NameSpace are:
C#
namespace QBPO.Application.Bpo.BusinessManagers
{
    using System;
    using System.Transactions;
    using QBPO.Application.Bpo.BusinessInterfaces;
    using QBPO.Application.Bpo.DataManagers;
    using QBPO.Entities.Bpo;
    using QBPO.Entities.Bpo.Entity.Interfaces;
    using QBPO.Entities.UserManagement;
    using QBPO.Framework;

}
Secondily this is the DataManagerCode where i am calling the method
C#
public int UpdateQCProcessed(IEntityBase entityBase)
      {
          int rowsAffected = int.MinValue;
          try
          {
              Logger.Write("Inside QBpoDataManager.UpdateQCProcessed()", LogType.Information);
              ICustomerLoanData customerLoanDataEntity = entityBase as ICustomerLoanData;
              CommonDataAccess.CreateStoredProcCommandWrapper(QBpoConstants.SPUPDATECUSTOMERLOANDATA);
              CommonDataAccess.AddInParameter(QBpoConstants.CUSTOMERLOANDATAID, DbType.Int32, customerLoanDataEntity.Id);
              CommonDataAccess.AddInParameter(QBpoConstants.UPDATEDON, DbType.DateTime, DateTime.Now.ObjectToDBDateTime());
              CommonDataAccess.AddInParameter(QBpoConstants.UPDATEDBY, DbType.Int32, customerLoanDataEntity.UpdatedBy);
              rowsAffected = CommonDataAccess.ExceuteNonQuery();
              Logger.Write("Exiting QBpoDataManager.UpdateQCProcessed()", LogType.Information);
          }
          catch (Exception exception)
          {
              throw exception;
          }

          return rowsAffected;
      }


and Namespace are:
C#
namespace QBPO.Application.Bpo.DataManagers
{
    using System;
    using System.Data;
    using System.Text;
    using QBPO.Entities.Bpo;
    using QBPO.Entities.Bpo.Entity.Interfaces;
    using QBPO.Entities.Common;
    using QBPO.Entities.UserManagement;
    using QBPO.Framework;
    using QBPO.Framework.Application;

}
Posted

1 solution

From the error results that your class "QBpoDataManager" does not have implemented the method "UpdateQCProcessed()" with the first parameter of type "QBpoDataManager".
So you have two solutions:
1) Your "QBpoDataManager" class should implement the IEntityBase interface;
OR
2)Extend the QBpoDataManager with a new method "UpdateQCProcessed()"that accept also QBpoDataManager as parameter.
 
Share this answer
 
Comments
[no name] 12-Feb-14 3:19am    
Thanks Buddy For your quick response.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900