B2CVaildCarNo bc = new B2CVaildCarNo(); bc.userName = “user*****“; bc.password = “Pwd*****“; bc.key = “key*****“; bc.receiverName = “张三“; bc.receiverCarNo = “43048219890301***“;
B2COrderServiceClient result = new B2COrderServiceClient(); if(result.ValidCarNo(bc).IsSuccess)
string waybillNum = result.Data;
else
string errorMessage = result.Message;
com.wms.B2C.client.B2CVaildCarNo carno=new com.wms.B2C.client.B2CVaildCarNo();
carno.setUserName("张三");
carno.setPassword("Pwd*****");
carno.setReceiverName("user*****");
carno.setKey("key*****");
carno.setReceiverCarNo("43048219890301***");
com.wms.B2C.client.IB2COrderService query=(com.wms.B2C.client.IB2COrderService) getWSObject("http://b2ctestservice.ekjshop.com/B2COrderService.svc?wsdl");
com.wms.B2C.client.ServiceResult result=query.validCarNo(carno);
System.out.println(result.getIsSuccess());