Its frightening how new I am to C# programming...
All i want to do is open a file and the write it on the console window.
using System;
using System.IO;
using System.Collections;
namespace simplerreader
{
class Program
{
public static void Main(string[] args)
{
string filepath = (@"somepath\bs.txt");
string read = File.ReadAllText(filepath);
Console.WriteLine(read);
Console.Write("Press any key to continue . . . ");
Console.ReadKey(true);
}
}
}
Result is:
012345678910111213141516171819
Press any key to continue . . .
Why am I getting numbers as the results?
Thank you for any assistance.
Still have the new programmer smell...This will be easy for you.
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.

pat7 reputationPosted Dec 7, 2008, 2:40 PM EST
Ryan AlfordRank #1,411 · 1.2K reputationPosted Dec 7, 2008, 6:20 PM EST