翻訳への提案を行います
 
他のユーザーによる提案:

progress indicator
他の提案はありません。
クリックして評価とフィードバックをお寄せください
MSDN
MSDN ライブラリ
.NET 開発
Silverlight
System.IO
StreamWriter クラス
 StreamWriter コンストラクター (Stream, Enco...
すべて縮小/すべて展開 すべて縮小
コンテンツの表示:   英語と日本語を並べて表示コンテンツの表示: 英語と日本語を並べて表示
.NET Framework Class Library for Silverlight
StreamWriter Constructor (Stream, Encoding)

Initializes a new instance of the StreamWriter class for the specified stream, using the specified encoding and the default buffer size.

Namespace:  System.IO
Assembly:  mscorlib (in mscorlib.dll)
Visual Basic (Declaration)
Public Sub New ( _
    stream As Stream, _
    encoding As Encoding _
)
C#
public StreamWriter(
    Stream stream,
    Encoding encoding
)

Parameters

stream
Type: System.IO..::.Stream
The stream to write to.
encoding
Type: System.Text..::.Encoding
The character encoding to use.
ExceptionCondition
ArgumentNullException

stream or encoding is nullNothingnullptra null reference (Nothing in Visual Basic).

ArgumentException

stream is not writable.

This constructor initializes the Encoding property using the encoding parameter, and the BaseStream property using the stream parameter. For additional information, see Encoding.

The StreamWriter object calls Dispose on the provided Stream object when StreamWriter..::.Dispose is called.

Caution noteCaution:

When you compile a set of characters with a particular cultural setting and retrieve those same characters with a different cultural setting, the characters might not be interpretable, and could cause an exception to be thrown.

Platform Notes

Silverlight for Windows Phone Silverlight for Windows Phone
 If you pass an invalid input path to a StreamWriter constructor, the constructor throws InvalidArgumentException instead of DirectoryNotFoundException.

Silverlight

Supported in: 5, 4, 3

Silverlight for Windows Phone

Supported in: Windows Phone OS 7.1, Windows Phone OS 7.0

XNA Framework

Supported in: Xbox 360, Windows Phone OS 7.0

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

.NET Framework Class Library for Silverlight
StreamWriter コンストラクター (Stream, Encoding)

指定したエンコーディングと既定のバッファー サイズを使用して、指定したストリーム用の StreamWriter クラスの新しいインスタンスを初期化します。

名前空間:  System.IO
アセンブリ :  mscorlib (mscorlib.dll 内)
Visual Basic (宣言)
Public Sub New ( _
    stream As Stream, _
    encoding As Encoding _
)
C#
public StreamWriter(
    Stream stream,
    Encoding encoding
)

パラメーター

stream
型 : System.IO..::.Stream
書き込まれるストリーム。
encoding
型 : System.Text..::.Encoding
使用する文字エンコーディング。
例外条件
ArgumentNullException

stream または encodingnullNothingnullptrnull 参照 (Visual Basic では Nothing) です。

ArgumentException

stream が書き込み可能ではありません。

このコンストラクターは、エンコーディング パラメーターを使用して Encoding プロパティを初期化し、stream パラメーターを使用して BaseStream プロパティを初期化します。 詳細については、Encoding のトピックを参照してください。

StreamWriter オブジェクトは、StreamWriter..::.Dispose が呼び出されたとき、提供されている Stream オブジェクトの Dispose を呼び出します。

Caution メモ注意 :

特定のカルチャ設定で文字セットをコンパイルし、同じ文字を異なるカルチャ設定で取得すると、文字が正しく解釈されない場合があり、例外がスローされることもあります。

プラットフォーム メモ

Silverlight for Windows Phone Silverlight for Windows Phone
StreamWriter コンストラクターに無効な入力パスを渡した場合は、コンストラクターが、DirectoryNotFoundException の代わりに InvalidArgumentException をスローします。

Silverlight

サポート対象 : 5、4、3

Silverlight for Windows Phone

サポート対象 : Windows Phone OS 7.1、Windows Phone OS 7.0

XNA Framework

サポート対象 : Xbox 360、Windows Phone OS 7.0

Silverlight でサポートされるオペレーティング システムの詳細については、「サポートされているオペレーティング システムとブラウザー」を参照してください。

コミュニティ コンテンツ   コミュニティ コンテンツとは
新しいコンテンツの追加 RSS  注釈
Processing
© 2012 Microsoft. All rights reserved. 使用条件 | 商標 | プライバシー
Page view tracker