Vote count:
0
I'm trying to create an asp.net webapplication using the eBay SDK to list items on ebay using the soap call AddItem API.
I'm trying to setup the shipping part of the AddItem api call using the code:
private ShippingDetailsType getShippingDetails()
{
ShippingDetailsType shippingDetails = new ShippingDetailsType();
SalesTaxType salesTax = new SalesTaxType();
salesTax.SalesTaxPercent = 0.2f;
salesTax.SalesTaxState = "UK";
shippingDetails.ApplyShippingDiscount = true;
//AmountType amount = new AmountType { Value = 2.8, currencyID = CurrencyUtility.GetDefaultCurrencyCodeType(_apiContext.Site) };
AmountType amount = new AmountType();
amount.Value = 3.99;
amount.currencyID = CurrencyCodeType.GBP;
shippingDetails.InsuranceFee = amount;
shippingDetails.InsuranceOption = InsuranceOptionCodeType.Optional;
shippingDetails.PaymentInstructions = "eBay .Net SDK";
// Set calculated shipping.
shippingDetails.ShippingType = ShippingTypeCodeType.Flat;
ShippingServiceOptionsType shippingOptions = new ShippingServiceOptionsType();
shippingOptions.ShippingService = ShippingServiceCodeType.ShippingMethodStandard.ToString();
shippingOptions.ShippingServiceAdditionalCost = amount;
shippingOptions.ShippingServiceCost = amount;
shippingOptions.ShippingServicePriority = 1;
shippingOptions.ShippingInsuranceCost = amount;
shippingDetails.ShippingServiceOptions = new ShippingServiceOptionsTypeCollection(new[] { shippingOptions });
return shippingDetails;
}
It underlines ShippingServiceOptionsTypeCollection
and says the namespace is missing. By the looks of it the soap call api does not have this. How do I setup the shipping please?
asked 44 secs ago
Unknown namespace ShippingServiceOptionsTypeCollection ebay SDK ASP.net
Aucun commentaire:
Enregistrer un commentaire