|
-
Sep 3rd, 2002, 12:57 AM
#1
Thread Starter
Addicted Member
reading a file
hummm I get a strange result when I try and read a file and put its contents in a textbox... here is the code:
<code>
string strPath= "C:\\test.log";
FileStream logFile = new FileStream(strPath, FileMode.Open);
int len =(int)logFile.Length;
byte [] logdata = new byte [len];
logFile.Read(logdata,0,len);
txtLogFile.Text = logdata.ToString();
</code>
for some reason the output (regardless of the file contents) is "System.Byte[]"
Any ideas? or know the right way to do this?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|