Click here to Skip to main content
15,868,016 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
i added this dll

SQL
namespace TCSCloud.Domain.RepairOrder.Model
{
    public class UpdateRepairOrder : Base.Base
    {
        public DateTime CreateDate { get; set; }
        public string CreateUser { get; set; }
        public DateTime LastUpdateDate { get; set; }
        public string LastUpdateUser { get; set; }
        public int TenId { get; set; }
        public int WorordId { get; set; } // Primary Key
        public string EstimateNumber { get; set; }
        public string WoNumber { get; set; }
        public string WoSource { get; set; }
        public string ReferenceNumber { get; set; }
        public string PoNumber { get; set; }
        public int CusId { get; set; }
        public int CusIdInvoiceTo { get; set; }
        public int CusIdWo { get; set; }
        public string CustomerName { get; set; }
        public string ContactName { get; set; }
        public string WoLocation { get; set; }
        public int CuslocId { get; set; }
        public int WorordtypId { get; set; }
        public int WorordcatId { get; set; }
        public int WorordunistaId { get; set; }
        public int ShosupId { get; set; }
        public int FacId { get; set; }
        public int WarId { get; set; }
        public int UniId { get; set; }
        public int ReeId { get; set; }
        public int OtReading { get; set; }
        public int RtReading { get; set; }
        public int HuboReading { get; set; }
        public string HuboReadingUom { get; set; }
        public string EstimateFlag { get; set; }
        public DateTime EstimateDate { get; set; }
        public DateTime EstimateCompleteDate { get; set; }
        public DateTime EstimateIntApprovedDate { get; set; }
        public DateTime EstimateCustomerHoldDate { get; set; }
        public DateTime EstimateCustApprovedDate { get; set; }
        public string EstimateNotes { get; set; }
        public DateTime WoDate { get; set; }
        public DateTime Completed_date { get; set; }
        public DateTime ApprovedDate { get; set; }
        public DateTime TransmitTimestamp { get; set; }
        public DateTime VoidDate { get; set; }
        public int TotalLabour { get; set; }
        public int TotalParts { get; set; }
        public int TotalShopsupply { get; set; }
        public int TotalSurcharge { get; set; }
        public int TotalTax { get; set; }
        public string Notes { get; set; }
        public string SystemNotes { get; set; }
        public string MobileNotes { get; set; }
        public string VoidNotes { get; set; }
        public int UseIdPreparedDy { get; set; }
        public int UseIdApprovedBy { get; set; }
        public int UseIdVoidedBy { get; set; }
        public string WoWsStatus { get; set; }
        public string UnitNumber { get; set; }
        public string UnitLicensePlate { get; set; }
        public string UnitSerialVin { get; set; }
        public string UnitReeferNumber { get; set; }
        public int UnitUnimakId { get; set; }
        public int UnitUnimodId { get; set; }
        public string UnitNotes { get; set; }
        public string CertificateLetter { get; set; }
        public int CertificateNumber { get; set; }
        public DateTime CertificateDate { get; set; }
        public string CertificateOther { get; set; }
        public string LastInsertUsername { get; set; }
        public string LastUpdateUsername { get; set; }
        public DateTime LastInsertDate { get; set; }
    }
}


i want to access these properties in my another class of another namespace but it doesn't although dll added successfully but not picking class

C#
using TCSCloud.Domain.RepairOrder;
using Oracle.DataAccess.Client;

namespace TcsCloud.Repository.RepairOrderManagement
{
    class RepairOrderManagementRepository
    {
        UpdateRepairOrder upd = new UpdateRepairOrder();
    }
}



Namespace UpdateRepairOrder couldn't be found ? why it is in TCSCloud.Domain.RepairOrder.Model and i added it's dll but it doesn't pick class, why ?
Posted
Comments
Maarten Kools 7-Mar-14 3:33am    
Have you added a reference to your assembly?

You're not importing the correct namespace, you should add a using directive to TCSCloud.Domain.RepairOrder.Model, because that's the namespace UpdateRepairOrder is in.
dan!sh 7-Mar-14 3:33am    
Have added reference to this DLL to your project?

1 solution

Look at your namespaces:
C#
namespace TCSCloud.Domain.RepairOrder.Model
{
    public class UpdateRepairOrder : Base.Base

And
C#
using TCSCloud.Domain.RepairOrder;
using Oracle.DataAccess.Client;

namespace TcsCloud.Repository.RepairOrderManagement
{
    class RepairOrderManagementRepository
    {
        UpdateRepairOrder upd = new UpdateRepairOrder();

The fully qualified name for UpdateRepairOrder is:
TCSCloud.Domain.RepairOrder.Model.UpdateRepairOrder

So either change your using to:
C#
using TCSCloud.Domain.RepairOrder.Model;
Or qualify your usage:
C#
Model.UpdateRepairOrder upd = new Model.UpdateRepairOrder();
 
Share this answer
 
Comments
Hunain Hafeez 7-Mar-14 3:46am    
ok all done and working but new problem is when i use 'upd.CreateDate' or upd.anyproperty
then it throws error Upd is field but used as a type

why ?
OriginalGriff 7-Mar-14 4:15am    
Without the code the complier is complaining about, I would have to guess - and that is a bad way to do development! :laugh:
Show me examples of the lines the compiler is not liking, and I'll see what I can do.

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