ruchika beddy 0 Light Poster

I m Using the Foll. method to Read the Contents of a File. If i m reading the doc,txt prog is working file. I m using the File "D:\pagefile.sys", ERROR is there,The process cannot access the file 'D:\pagefile.sys' because it is being used by another process.
how To Read Contents of "D:\pagefile.sys".
Need UR Help!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!


Imports System.io
Module Module1

Sub Main()
Dim fs As FileStream
fs = New FileStream("D:\Documents and Settings\Administrator\Desktop\SCAN%20HDDDDDDDDDDDDDDDD[1].doc", FileMode.Open, FileAccess.ReadWrite, FileShare.Read)
Dim d As New StreamReader(fs)

d.BaseStream.Seek(0, SeekOrigin.Begin)

While d.Peek() > -1
Console.WriteLine(d.ReadToEnd)
Console.ReadLine()
End While
d.Close()


End Sub

End Module