Object reference not set to an...
ההודעה שלי לא קופצת יותר, אז העלתי אותה שוב בתקווה שתקפוץ
ההודעה שלי לא קופצת יותר, אז העלתי אותה שוב בתקווה שתקפוץ
Object reference not set to an instance of an object. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.NullReferenceException: Object reference not set to an instance of an object. Source Error: Line 76: Dim mMsgs() As Message Line 77: For Each sFile In dirs Line 78: mMsgs(iMessage).sSubject = ReadFile(sFile, 900) Line 79: iMessage += 1
Message זו מחלקה קטנה שנראית בינתיים ככה:Public Class Message Public sSubject, sFrom, sTo, sBCC, sBody As String Public iMimeParts As Integer End Class
המשתנים:Dim iMessage As Integer Dim mMsgs() As Message
ניסיתי גם את זה: אבל זה לא עזרFor Each sFile In dirs mMsgs(iMessage) = New Message() mMsgs(iMessage).sSubject = ReadFile(sFile, 900) iMessage += 1 Next
נראה לי שאלו כל הנתונים הנדרשים