2011-02-10 4 views
2

FedEx国際船舶サービスとの統合中です。しかし、私は本当に1つの部分に立ち往生しています。テスト環境を使って原産地証明書を作成しようとしています。私は、XMLスキーマに従っているとFedEx出荷サービスWSDLを使用した文書の作成

private static void SetCustomInvoice(ProcessShipmentRequest request) 
    { 
     request.RequestedShipment.ShippingDocumentSpecification = new ShippingDocumentSpecification(); 
     request.RequestedShipment.ShippingDocumentSpecification.ShippingDocumentTypes = new RequestedShippingDocumentType[1] { new RequestedShippingDocumentType() }; 
     request.RequestedShipment.ShippingDocumentSpecification.ShippingDocumentTypes[0] = RequestedShippingDocumentType.CERTIFICATE_OF_ORIGIN; 
     request.RequestedShipment.ShippingDocumentSpecification.CertificateOfOrigin = new CertificateOfOriginDetail(); 
     request.RequestedShipment.ShippingDocumentSpecification.CertificateOfOrigin.DocumentFormat = new ShippingDocumentFormat { StockType = ShippingDocumentStockType.STOCK_4X6, ImageType = ShippingDocumentImageType.PDF, ImageTypeSpecified = true, StockTypeSpecified = true }; 
     request.RequestedShipment.SpecialServicesRequested = new ShipmentSpecialServicesRequested(); 
     request.RequestedShipment.SpecialServicesRequested.SpecialServiceTypes = new ShipmentSpecialServiceType[1] { new ShipmentSpecialServiceType() }; 
     request.RequestedShipment.SpecialServicesRequested.SpecialServiceTypes[0] = ShipmentSpecialServiceType.ELECTRONIC_TRADE_DOCUMENTS; 

     request.RequestedShipment.SpecialServicesRequested.EtdDetail = new EtdDetail(); 
     request.RequestedShipment.SpecialServicesRequested.EtdDetail.RequestedDocumentCopies = new RequestedShippingDocumentType[1] { RequestedShippingDocumentType.CERTIFICATE_OF_ORIGIN }; 
     request.RequestedShipment.SpecialServicesRequested.EtdDetail.DocumentReferences = new UploadDocumentReferenceDetail[1] { new UploadDocumentReferenceDetail() }; 
     request.RequestedShipment.SpecialServicesRequested.EtdDetail.RequestedDocumentCopies[0] = RequestedShippingDocumentType.CERTIFICATE_OF_ORIGIN; 

    } 

以下のコードが出ている。しかし、私は戻って、「無効な証券の種類」を述べたWebサービスからのエラーメッセージを取得しておきます。 shipmentDocumentStockTypeは列挙型で、その値の1つを使用しています。私はまだこのエラーが発生しています。私が間違っているかもしれないどんなアイデア? すべての情報は大きな助けになります。私はFedExのテクニカルサポートに連絡しようとしましたが、本当に大きな助けにはなりませんでした。

答えて

5

これは少し遅れているかもしれませんが、他の人がそれを探している場合に備えて回答を提供したいだけです。

私は同様の問題を抱えていましたが、Certificate of Originの代わりに商用請求書がありました。

から: request.RequestedShipment.ShippingDocumentSpecification.CertificateOfOrigin.DocumentFormat = new ShippingDocumentFormat { StockType = ShippingDocumentStockType.STOCK_4X6, ImageType = ShippingDocumentImageType.PDF, ImageTypeSpecified = true, StockTypeSpecified = true };

へ: request.RequestedShipment.ShippingDocumentSpecification.CertificateOfOrigin.DocumentFormat = new ShippingDocumentFormat { StockType = ShippingDocumentStockType.PAPER_LETTER, ImageType = ShippingDocumentImageType.PDF, ImageTypeSpecified = true, StockTypeSpecified = true };

これらのフォームは私のためにそれを固定PAPER_LETTERするのでSTOCK_4x6からStockTypeを変更し、PDF形式の完全な8.5×11ページに印刷する必要が判明

希望すると便利です

関連する問題