שלח תשובה

זירת השאלות

667
צפיות
12
תשובות

runtime error

,‏ 20 ביולי, 2006

שלום

קבלתי עבודה ראשונה.

העלתי קובץ aspx ,שמעדכן database באתר עסקי, לשרת עסקי.

במחשב שלי הכול הלך כשורה.

באתר קבלתי שגיאה שבשביל להתחיל לראות אותה עלי לשנות הגדרות ב-

web.configuration

ניסיתי לשנות הגדרות ב-web.con אך ללא הועיל

מישהו מכיר את הנושא?

Runtime Error



Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".

<!– Web.Config Configuration File –>

<configuration>
    <system.web>
        <customErrors mode="Off"/>
    </system.web>
</configuration>

Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.

<!– Web.Config Configuration File –>

<configuration>
    <system.web>
        <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
    </system.web>
</configuration>

תגיות:

12 תשובות

  1. kedem הגיב:

    oleDbconnection
    שלום לכולם
    אני מנסה לפתוח חיבור oleDbconnection ל-access בשרת עסקי
    ואני לא מצליח אצלי במחשב אני כן מצליח הנה הקוד:
    Dim Conn As New OleDbConnection( _
           "Provider=Microsoft.Jet.OLEDB.4.0;" & _
           "Data Source=mail.mdb")

        Dim objCmd As New OleDbCommand _
               ("SELECT * FROM maillist2", Conn)
          dim objReader as OleDbDataReader
          
          try
             objCmd.Connection.Open()
             objReader = objCmd.ExecuteReader()
          catch ex as Exception
             lblMessage.Text = "Error retrieving from the database. Please" & _
                " make sure all values are correctly input"
          end try

  2. זהר פלד הגיב:

    שרשר שאלותיך
    להבא, תיישר את הקוד לשמאל. יש אייקון של ישור לשמאל בצד השמאלי של שורת האייקונים של תוכן ההודעה, תשתמש בו.

    Dim Conn As New OleDbConnection( _
           "Provider=Microsoft.Jet.OLEDB.4.0;" & _
           "Data Source=mail.mdb")

        Dim objCmd As New OleDbCommand _
               ("SELECT * FROM maillist2", Conn)
          dim objReader as OleDbDataReader
          
          try
             objCmd.Connection.Open()
             objReader = objCmd.ExecuteReader()
          catch ex as Exception
             lblMessage.Text = "Error retrieving from the database. Please" & _
                " make sure all values are correctly input"
          end try

    ודבר שלישי, תעיף את ה try catch, תראה איזה הודעת שגיאה אתה מקבל, ותעתיק אותה לפורום.
    לקריאה נוספת

  3. kedem הגיב:

    עדיין החיבור לא נפתח
    הדף עולה אין שגיאה אבל אין השפעה על ה-database

  4. kedem הגיב:

    החיבור נפתח
    תודה
    אני מצליח לראות את הקובץ.
    שאלה נוספת:
    הקובץ אמור להיות בשרת לפני ה-www
    השאלה היא איך ב-(server.mappath("northwind.mdb"))
    אני מנתב כמה תיקיות לפני המיקום הנוכחי

  5. kedem הגיב:

    server error

                                                                                           שלום
                                פתחתי קובץ לקריאה ע"מ לשלוח מייל קבוצתי – באתר עסקי
                                             הכל טוב ויפה,כשאני לוחץ שלח אני מקבל שגיאה

    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 26:            
    Line 27:             Dim objEmail As New MailMessage
    Line 28:             objEmail.To = objReader.GetString(0)        שגיאה
    Line 29:             objEmail.From = From.Value
    Line 30:             objEmail.Subject = "Test Email"

                                                                                        יש למשהו רעיון  

  6. gilad123 הגיב:

    רעיון
    הרעיון הראשון הוא לישר את הטקסט לשמאל שיהיה אפשר לקרוא…


    objReader.GetString(0)

    בטוח שהוא מחזיר משהו?

  7. kedem הגיב:

    תודה
    איכשהו הסתדרתי
    אני לא יכול להצביע על הבעיה
    בעל אופן תודה!

  8. kedem הגיב:

    איך יורדים שורה ב-vb.net
    לדוגמא:                                                                                       |הקוד
    objEmail.Body = body.Value & "בלה בלה"

                                                               ?שה-בודי יופיע לפני המחרוזת ומעליה  

                                                                           .לגבי ההודעה למעלה נפלט לי                                                  

שלח תשובה