IsolatedStorageFileStream.ReadByte Método

Definição

Lê um único byte do IsolatedStorageFileStream objeto no armazenamento isolado.

public:
 override int ReadByte();
public override int ReadByte();
override this.ReadByte : unit -> int
Public Overrides Function ReadByte () As Integer

Retornos

O valor inteiro sem sinal de 8 bits lido do arquivo de armazenamento isolado.

Exemplos

O exemplo de código a seguir demonstra como o ReadByte método pode ser usado para ler dados de um IsolatedStorageFileStream objeto. Para obter o contexto completo deste exemplo, consulte a IsolatedStorageFileStream visão geral.

Console.WriteLine("Writing data to the new file.");
while (source.Position < source.Length)
{
    inputChar = (byte)source.ReadByte();
    target.WriteByte(inputChar);
}

// Determine the size of the IsolatedStorageFileStream
// by checking its Length property.
Console.WriteLine("Total Bytes Read: " + source.Length);
Console.WriteLine("Writing data to the new file.")
While source.Position < source.Length
    inputChar = CByte(source.ReadByte())
    target.WriteByte(inputChar)
End While

' Determine the size of the IsolatedStorageFileStream
' by checking its Length property.
Console.WriteLine(("Total Bytes Read: " & source.Length))

Aplica-se a