There are lots of possible duplicates for this post.But i tried most of thems, unfortunately my error still
happens.

> 
> Error is : Error 1 Cannot implicitly convert type `'System.Collections.Generic.List<Report.Business.ViewModels.InvoiceMaster>'` to `'System.Collections.Generic.IList<ICSNew.Data.InvoiceHD>'`. An explicit conversion exists (are you missing a cast?)
> 
> 
> 

```
public IList<InvoiceHD> GetAllInvoiceMasterDetailsByInvoiceId(int InvoiceId)
{
    var dbMstDtl = ireportrepository.GetAllInvoiceMasterDetailsByInvoiceId(InvoiceId);

    var MstDtl = from mst in dbMstDtl 
                 select new Report.Business.ViewModels.InvoiceMaster 
                 {
                     ModifiedDate = mst.ModifiedDate,
                     SubTotal = Convert.ToDecimal(mst.SubTotal),
                     TotalDiscount = Convert.ToDecimal(mst.TotalDiscount),
                     VAT = Convert.ToDecimal(mst.VAT),
                     NBT = Convert.ToDecimal(mst.NBT),
                     AmtAfterDiscount = Convert.ToDecimal(mst.AmtAfterDiscount)
                 };

    return MstDtl.ToList();
}

```

In some post i saw this thing solved when they use **return MstDtl.AsEnumerable().ToList();**

But in my case it also not working(getting errors)