Dynamicweb.eCommerce.Orders Namespace : OrderCaptureInfo Class |
'Declaration
<SerializableAttribute()> Public Class OrderCaptureInfo
[SerializableAttribute()] public class OrderCaptureInfo
class MyPage : System.Web.UI.Page { public Dynamicweb.eCommerce.Orders.OrderCaptureInfo Capture(Dynamicweb.eCommerce.Orders.Order order) { try { if (order == null || string.IsNullOrEmpty(order.ID) || string.IsNullOrEmpty(order.TransactionNumber)) { string errorText = null; if (string.IsNullOrEmpty(order.TransactionNumber)) { errorText = "No transaction number set on the order"; } else { errorText = "No valid Order object set"; } return new Dynamicweb.eCommerce.Orders.OrderCaptureInfo(Dynamicweb.eCommerce.Orders.OrderCaptureInfo.OrderCaptureState.Failed, errorText); } string infoText = "Remote Capture succeeded"; return new Dynamicweb.eCommerce.Orders.OrderCaptureInfo(Dynamicweb.eCommerce.Orders.OrderCaptureInfo.OrderCaptureState.Success, infoText); } catch (Exception ex) { string infoTxt = string.Format("Remote capture for order {0} failed with the message: {1}", order.ID, ex.Message); return new Dynamicweb.eCommerce.Orders.OrderCaptureInfo(Dynamicweb.eCommerce.Orders.OrderCaptureInfo.OrderCaptureState.Failed, infoTxt); } } }
System.Object
Dynamicweb.eCommerce.Orders.OrderCaptureInfo
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2