My guess is this is coming from the shippingMethods property where .First() is called, but it would potentially appear that the collection is empty. Are you sure you have some shipping methods defined that have been configured to be allowed in the shippingCountryId?
I did not set a Default Shipping Method for the selected country.
Is there a way of setting one shipping method as Default in all countries?
Since we have vreated all countries from ISO 3166 this would be a rather time consuming task to set the Default Shipping Method individually.
Unfortunately not. This currently need to be set manually, or via code. You could write some quick code to loop through all the countries and set it's default shipping method if not set.
currentShippingMethodId - Handling 'Sequence has no elements' Exception
Hi Matt,
we are encountering the following error:
For some reason the currentShippingMethodId is null when currentOrder has an id and for example CountryId has a value.
What would be the easiest workaround?
Thanks
Hi Edgar,
My guess is this is coming from the
shippingMethods
property where.First()
is called, but it would potentially appear that the collection is empty. Are you sure you have some shipping methods defined that have been configured to be allowed in theshippingCountryId
?Matt
Problem solved.
I did not set a Default Shipping Method for the selected country.
Is there a way of setting one shipping method as Default in all countries? Since we have vreated all countries from ISO 3166 this would be a rather time consuming task to set the Default Shipping Method individually.
Thanks
Hi Edgar,
Unfortunately not. This currently need to be set manually, or via code. You could write some quick code to loop through all the countries and set it's default shipping method if not set.
Matt
is working on a reply...