SoapMessage.ContentType プロパティ
アセンブリ: System.Web.Services (system.web.services.dll 内)

Dim instance As SoapMessage Dim value As String value = instance.ContentType instance.ContentType = value
/** @property */ public String get_ContentType () /** @property */ public void set_ContentType (String value)
SOAP 要求または SOAP 応答の HTTP Content-Type。既定値は、"text/xml" です。


ContentType プロパティには、BeforeSerialize の段階および BeforeDeserialize の段階に限りアクセスできます。それ以外の場合は InvalidOperationException がスローされます。
SOAP メッセージのエンコードに関する補足情報を提供するには、ContentType プロパティの代わりに、ContentEncoding プロパティを使用してください。

myStreamWriter.WriteLine("The contents of HTTP Content-type header
is:")
myStreamWriter.WriteLine(ControlChars.Tab & message.ContentType)
myStreamWriter.WriteLine("The contents of HTTP Content-type header is:"); myStreamWriter.WriteLine("\t" + message.ContentType);
myStreamWriter->WriteLine( "The contents of HTTP Content-type header is:" ); myStreamWriter->WriteLine( "\t{0}", message->ContentType );

Windows 98, Windows 2000 SP4, Windows CE, Windows Millennium Edition, Windows Mobile for Pocket PC, Windows Mobile for Smartphone, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Weblioに収録されているすべての辞書からSoapMessage.ContentType プロパティを検索する場合は、下記のリンクをクリックしてください。

- SoapMessage.ContentType プロパティのページへのリンク