Visualizzazione dei risultati da 1 a 2 su 2

Discussione: Perchè.....

  1. #1

    Perchè.....

    .....mi da questo errore?

    codice:
    Server Error in '/' Application.
    --------------------------------------------------------------------------------
    
    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".
    
    
    
    
    <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.
    
    
    
    
    <configuration>
        <system.web>
            <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
        </system.web>
    </configuration>
    Questo è lo script:

    codice:
    <%@ Page %>
    <%@ Import Namespace="System.IO" %>
    <%@ Import Namespace="System.Net" %>
    <script language="C#" runat="server">
    
    private void Page_Load(System.Object sender, System.EventArgs e){
    	String RequestUrl = "http://www.3isolutions.it";
    	
    	HttpWebRequest WebRequestObject = null;
    	StreamReader risposta = null;
    	HttpWebResponse WebResponseObject = null;
    	
    	try{
    		WebRequestObject = (HttpWebRequest) WebRequest.Create(RequestUrl);
    		WebRequestObject.Method = "GET";
    
    		WebResponseObject = (HttpWebResponse) WebRequestObject.GetResponse();
    		risposta = new StreamReader(WebResponseObject.GetResponseStream());
    		
    		String pagina = risposta.ReadToEnd();
    		web_output.Text = pagina;
    	}
    	finally{
    		try{
    			risposta.Close();
    		}
    		catch{}
    		
    		try{
    			WebResponseObject.Close();
    			WebRequestObject.Abort();
    		}
    		catch{}
    	}
    }
    
    </script>
    <html>
    	<head>
    		<title></title>
    	</head>
    	<body>
    <table width="780" cellspacing="0" cellpadding="0" align="center" border="0">
    		<tr>
    			<td colspan="5">
    				
    			</td>
    		</tr>
    		<tr bgcolor="<%=Navigazione_Sfondo%>">
    			<td colspan="5" width="780">
    				
    			</td>
    		</tr>
    		<tr>
                            <td width="500" bgcolor="<%=TabellaBig_Colore_Cx%>" valign="top">
                                                    <form runat="server" ID="Form1">
    			                              <asp:Label Runat="server" ID="web_output" />
                                              		</form>
             		</td>
             		</tr>
    </table>
    		<table width="780" cellspacing="0" cellpadding="0" border="0" bgcolor="<%=Tabella_Colore_Titolo%>" style="border-collapse: collapse" bordercolor="#111111" align="center">
    			<td>
                            		
                            </td>
            	</table>
    </body>
    </html>
    	</body>
    </html>

  2. #2
    Utente di HTML.it
    Registrato dal
    Sep 2002
    Messaggi
    4,127
    fai quello ke ti dice e cosi potrai vedere la riga precisa dell'errore

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.