bhavna_816 0 Junior Poster

There is a filestream and a streamwriter in Sub Main()
Dim fs As New FileStream("c:\OL_Table.htm", FileMode.Create, FileAccess.Write)
Dim s As New StreamWriter(fs)
//code goes here
s.Close()
fs = New FileStream("c:\OL_Table.htm", FileMode.Open, FileAccess.Read)
Dim d As New StreamReader(fs)
d.BaseStream.Seek(0, SeekOrigin.Begin)
and there is a class having functions
Public Class MailItemClass
Function1: Public Function DisplayMails(ByVal PFolder As Object, ByVal SFolder As Object) As String
Function2: Public Function DisplayBody(ByVal PFolder As Object, ByVal SFolder As Object, ByVal Msg As Object) As String
which display mailitems and the message body respectively.
I want to display these mailitems and the message body in the HTML page having filestream and streamwriter i.e. "s"
but the filestream and a streamwriter are not accessible in the class functions.
how can i display the mailitems and the message body in the same HTML page in the Sub Main()