How can I resolve this error 'IEnumerable<SelectListItem>' in the drop down list MVC
<p>In my MVC project I pass list of currencies to the view within the drop down list. However, once I try to post the view I get the following exception:</p>

<blockquote>
  <p>The ViewData item that has the key 'FromCurrencyId' is of type
  'System.Int32' but must be of type 'IEnumerable'.</p>
</blockquote>

<p>Currency Controller</p>

<pre><code>namespace Project.Controllers
{
    public class CurrencyController : Controller
    {
      [HttpGet]
        // GET: Currency
        public ActionResult Index()
        {

            CurrenciesClient Cur = new CurrenciesClient();
            var listCurrency = Cur.findAll().ToList();

            Currencies model = new Currencies();
            model.FromCurrencies = new SelectList(listCurrency, "Id", "CurrencyName");
            model.ToCurrencies = new SelectList(listCurrency, "Id",  "CurrencyName");

            return View(model);

        }

        [HttpPost]
        public ActionResult Index(Currencies cur)
        {


            if (ModelState.IsValid)
            {
                if (cur.FromCurrencyId == cur.ToCurrencyId)
                {
                    //do something if same currecnies and return.
                    ModelState.AddModelError("CurrencyCountry", "Can't make the conversion for the same value");
                }
                else
                {
                   some code .....
                }
            }

            return View(cur);

        }
    }
}
</code></pre>

<p>Currencies VM</p>

<pre><code>namespace Project.ViewModels
{
    public class Currencies
    {
        public int Id { get; set; }
        [Required]
        public int FromCurrencyId { get; set; }
        public SelectList FromCurrencies { get; set; }

        [Required]
        public int ToCurrencyId { get; set; }
        public SelectList ToCurrencies { get; set; }

        public string CurrencyName { get; set; }

        public string CurrencyCountry { get; set; }


        [Required]
        public decimal ConversionRate { get; set; }

        public decimal Value { get; set; }

        public SelectList AvailableCurrencies { get; set; }


    }
}
</code></pre>

<p>CurrencyClient web service VM</p>

<pre><code>namespace Project.ViewModels
{
    public class CurrenciesClient 
    {
        private string base_Url = "http://localhost:51646/api/";

        public IEnumerable&lt;Currencies&gt; findAll()
        {
            try
            {
                HttpClient client = new HttpClient();
                client.BaseAddress = new Uri(base_Url);
                client.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json"));
                HttpResponseMessage response = client.GetAsync("currencies").Result;
                if (response.IsSuccessStatusCode)
                {
                    var resposeData = response.Content.ReadAsStringAsync().Result;
                    var Currency = JsonConvert.DeserializeObject&lt;List&lt;Currencies&gt;&gt;(resposeData);
                    return Currency;


                }
                return null;

            }
            catch
            {
                return null;
            }
        }
    }
}
</code></pre>

<p>Index View</p>

<pre><code>model Project.ViewModels.Currencies

@{
    ViewBag.Title = "Index";
}


@using (Html.BeginForm("Index", "Currency", FormMethod.Post))
{
    @Html.TextBoxFor(m =&gt; m.ConversionRate, new { @size = "5" })
    @Html.DropDownListFor(m =&gt; m.FromCurrencyId, Model.FromCurrencies as IEnumerable&lt;SelectListItem&gt;)
      @Html.DropDownListFor(m =&gt; m.ToCurrencyId, Model.ToCurrencies as IEnumerable&lt;SelectListItem&gt;)
        &lt;button type="submit" class="btn btn-primary"&gt;Convert&lt;/button&gt;
}
</code></pre>