のために定義されていませんパラメータなしのコンストラクタ私は私のWCFサービスの突然の全てにこのエラーを取得しています:値である可能性が真IncludeExceptionDetailInFaults =が作成したこのオブジェクトエラー
アンExceptionDetail、:
System.InvalidOperationException: An exception was thrown in a call to a WSDL export extension:
System.ServiceModel.Description.DataContractSerializerOperationBehavior contract:
http://tempuri.org/:IListingService ----> System.MissingMethodException: No parameterless constructor defined
for this object.
at
System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck) at
System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache) at
System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipVisibilityChecks, Boolean skipCheckThis, Boolean fillCache) at
System.Activator.CreateInstance(Type type, Boolean nonPublic) at
System.Runtime.Serialization.SchemaExporter.InvokeGetSchemaMethod(Type clrType, XmlSchemaSet schemas, XmlQualifiedName stableName) at
System.Runtime.Serialization.SchemaExporter.ExportXmlDataContract(XmlDataContract dataContract) at
System.Runtime.Serialization.SchemaExporter.Export() at
System.Runtime.Serialization.XsdDataContractExporter.Export(Type type)
私はすべてのクラスにパラメータを持たないpublicコンストラクタを持っていますが、それでも私にはこのエラーが出ます。私は何が欠けていますか?
問題が見つかりました。私はプロパティタイプ(MongoDBのサードパーティタイプ)にOIdを使用していましたが、私はこれらのクラスに属性を追加しました。これはint型に変更されて動作し始めましたが、OIdプロパティは何週間もうまく働いていたのですが、何が変わったのでしょうか... – Justin
問題を解決した場合は、回答。 –