using System;
using System.IO;
namespace
FileOperationsSample
{
class Program
{
public static void Main(String[] args)
{
String
str = "I am string";
// We
need to create an array with size of string length
char[]
b = new char[str.Length];
// Load
string in a StringReader
StringReader
sr = new StringReader(str);
sr.Read(b, 0, 11);
Console.WriteLine(b);
sr.Close();
Console.ReadLine();
}
}
}