2011-12-20 6 views
0

WCFサービスを呼び出すWPFプログラムがあります。それはすべて私のPC上で正常に動作しますが、顧客のPCで私は次のエラーが発生します。WCFサービスコールによりTypeLoadExceptionが発生する

[フッタ] [ヘッダー] 2011-12-20 10:54:29809 [5] Kern.Common.Logging.Logger WARN - のエラーロギング - 例外結果を作り、動作中 を発生無効。例外の詳細については、InnerException を確認してください。 Kern.Common.Logging.Logger - 内部例外 - System.TypeLoadException:型 'ChannelBaseをロードできませんでした1' from assembly 'System.ServiceModel, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'. at KernMobile.Data.Server.KernMobileWcfService.KernServiceClient.CreateChannel() at System.ServiceModel.ClientBase 1.CreateChannelInternal()を にSystem.ServiceModel.ClientBase 1.get_Channel() at KernMobile.Data.Server.KernMobileWcfService.KernServiceClient.KernMobile.Data.Server.KernMobileWcfService.IKernService.BeginLogin(String username, String password, AsyncCallback callback, Object asyncState) at KernMobile.Data.Server.KernMobileWcfService.KernServiceClient.OnBeginLogin(Object[] inValues, AsyncCallback callback, Object asyncState) at System.ServiceModel.ClientBase 1.InvokeAsync

私はトレースWCFオン(BeginOperationDelegate beginOperationDelegateは、[] inValues、endOperationDelegate endOperationDelegate、SendOrPostCallback operationCompletedCallback、 オブジェクトuserStateオブジェクト)が、ログファイルに報告されたエラーはありません。ここで

は、サービスの設定です:

<system.serviceModel> 
    <bindings> 
     <basicHttpBinding> 
     <binding name="BasicHttpBinding_IKernService" closeTimeout="00:01:00" 
      openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00" 
      allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" 
      maxBufferSize="2147483647" maxBufferPoolSize="524288" maxReceivedMessageSize="2147483647" 
      messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered" 
      useDefaultWebProxy="true"> 
      <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384" 
       maxBytesPerRead="4096" maxNameTableCharCount="16384" /> 
      <security mode="None"> 
      <transport clientCredentialType="None" proxyCredentialType="None" 
       realm="" /> 
      <message clientCredentialType="UserName" algorithmSuite="Default" /> 
      </security> 
     </binding> 
     </basicHttpBinding> 
    </bindings> 

    <client> 
     <endpoint address="http://localhost/Kern.Server.Service/KernService.svc" 
      binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_IKernService" 
      contract="KernMobileWcfService.IKernService" name="BasicHttpBinding_IKernService" /> 
    </client> 
    </system.serviceModel> 

任意のアイデア?

+0

.NET Framework v4.0がクライアントマシンにインストールされていることを確認してください。また、依存するDLLがすべて使用可能かどうかも確認してください。 – Rajesh

答えて

0

最後にこれを修正しました。

これは、ポータブルライブラリプロジェクトをWCFサービス参照のラッパーとして使用することによって発生しました。

これはほとんどのPCでうまくいきましたが、ハードウェアをロックダウンした顧客では失敗しました。いくつかのサポートDLLがないと仮定しています。

通常のクラスライブラリプロジェクトに変更され、すべてが機能しました。

関連する問題