Ссылка на библиотеку Stripe: Stripe.net
Версия среды выполнения: v4.0.30319
Версия: 25.2.0.0
при получении ответа от полосы и вызове функции заряда () в процессе полученияошибка «Не удалось загрузить файл или сборку» System.Collections.Immutable, Version = 1.2.3.0, Culture = нейтральный »в коде, указанном ниже
<form action="/Pay/Charge" method="POST">
<article>
<label>Amount: $5.00</label>
</article>
<script src="//checkout.stripe.com/v2/checkout.js"
class="stripe-button"
data-key="@ViewBag.StripePublishKey"
data-locale="auto"
data-description="Sample Charge"
data-amount="500">
</script>
</form>
Это представление вызывает нижеуказанный заряд ActionResult
public ActionResult Charge(string stripeEmail, string stripeToken)
{
var customers = new CustomerService();
var charges = new ChargeService();
var customer = customers.Create(new CustomerCreateOptions
{
Email = stripeEmail,
SourceToken = stripeToken
});
//Error on this line--↓
var charge = charges.Create(new ChargeCreateOptions
{
Amount = 500,
Description = "Sample Charge",
Currency = "usd",
CustomerId = customer.Id
});
// further application specific code goes here
return View();
}
Additional information: Could not load file or assembly 'System.Collections.Immutable, Version=1.2.3.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
InnerException:Null