Impossibile aprire pagine .aspx

niespolo

Nuovo Utente
8 Set 2006
1
0
0
Salve,

sono alle prime armi con la programmazione ASP .NET. Sotto Windows 2003 Server, e usando Visual Studio 2003, non riesco ad aprire, da IIS, una pagina HelloWorld.aspx che contiene il codice seguente:

<%@ page language="C#" Debug="true" %>
<html>
<head>
<title></title>

</head>
<body>

<h1>Hello world!</h1>

</body>
</html>

in quanto viene aperto il browser Internet Explorer che visualizza una pagina il cui codice è (lo riporto non potendo inserire file allegati):

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- saved from url=(0049)http://localhost/ASPNETStepbyStep/HelloWorld.aspx -->
<HTML><HEAD><TITLE>Server cannot access application directory 'D:\Documents and Settings\Administrator\My Documents\Visual Studio Projects\'. The directory does not exist or is not accessible because of security settings.</TITLE>
<META http-equiv=Content-Type content="text/html; charset=windows-1252">
<STYLE>BODY {
FONT-WEIGHT: normal; FONT-SIZE: 0.7em; COLOR: black; FONT-FAMILY: "Verdana"
}
P {
MARGIN-TOP: -5px; FONT-WEIGHT: normal; COLOR: black; FONT-FAMILY: "Verdana"
}
B {
MARGIN-TOP: -5px; FONT-WEIGHT: bold; COLOR: black; FONT-FAMILY: "Verdana"
}
H1 {
FONT-WEIGHT: normal; FONT-SIZE: 18pt; COLOR: red; FONT-FAMILY: "Verdana"
}
H2 {
FONT-WEIGHT: normal; FONT-SIZE: 14pt; COLOR: maroon; FONT-FAMILY: "Verdana"
}
PRE {
FONT-SIZE: 0.9em; FONT-FAMILY: "Lucida Console"
}
.marker {
FONT-WEIGHT: bold; COLOR: black; TEXT-DECORATION: none
}
.version {
COLOR: gray
}
.error {
MARGIN-BOTTOM: 10px
}
.expandable {
FONT-WEIGHT: bold; CURSOR: hand; COLOR: navy; TEXT-DECORATION: underline
}
</STYLE>

<META content="MSHTML " name=GENERATOR></HEAD>
<BODY bgColor=white><SPAN>
<H1>Server Error in '/ASPNETStepbyStep' Application.
<HR width="100%" color=silver SIZE=1>
</H1>
<H2>Server cannot access application directory 'D:\Documents and
Settings\Administrator\My Documents\Visual Studio Projects\'. The directory does
not exist or is not accessible because of security settings.
</H2></SPAN><FONT
face="Arial, Helvetica, Geneva, SunSans-Regular, sans-serif "><B>Description:
</B>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. <BR><BR><B>Exception Details:

</B>System.Web.HttpException: Server cannot access application directory
'D:\Documents and Settings\Administrator\My Documents\Visual Studio Projects\'.
The directory does not exist or is not accessible because of security
settings.<BR><BR><B>Source Error:</B> <BR><BR>
<TABLE width="100%" bgColor=#ffffcc>
<TBODY>
<TR>
<TD>
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.

</TD></TR></TBODY></TABLE><BR><B>Stack Trace:</B> <BR><BR>
<TABLE width="100%" bgColor=#ffffcc>
<TBODY>

<TR>
<TD>
<PRE>
[HttpException (0x80004005): Server cannot access application directory 'D:\Documents and Settings\Administrator\My Documents\Visual Studio Projects\'. The directory does not exist or is not accessible because of security settings.]
System.Web.HttpRuntime.EnsureAccessToApplicationDirectory() +72
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +263

[HttpException (0x80004005): ASP.NET Initialization Error]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +964
System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr) +128
</PRE>
</TD></TR></TBODY></TABLE><BR>
<HR width="100%" color=silver SIZE=1>
<B>Version Information:</B>&nbsp;Microsoft .NET Framework Version:;
ASP.NET Version: </FONT><!--
[HttpException]: Server cannot access application directory 'D:\Documents and Settings\Administrator\My Documents\Visual Studio Projects\'. The directory does not exist or is not accessible because of security settings.
at System.Web.HttpRuntime.EnsureAccessToApplicationDirectory()
at System.Web.HttpRuntime.FirstRequestInit(HttpContext context)
[HttpException]: ASP.NET Initialization Error
at System.Web.HttpRuntime.FirstRequestInit(HttpContext context)
at System.Web.HttpRuntime.ProcessRequestInternal(HttpWorkerRequest wr)
--></BODY></HTML>

Basta copiare il contenuto e salvarlo come file .htm per visualizzarlo correttamente. La directory virtuale esiste e contiene il file HelloWorld.aspx. Accedo come amministratore ed ho tutti i permessi sull'applicazione Helloworld che ho creato.
Non ci sono problemi se invece provo ad aprire una pagina html. Sembra quindi che non sia possibile eseguire il codice <%@ page language="C#" Debug="true" %> perchè da qualche parte non ne verrebbe consentita l'esecuzione...Spero di ricevere un aiuto util, saluti.
 
Discussioni simili
Autore Titolo Forum Risposte Data
ste80 [MS Access] Impossibile aprire una maschera da pulsante MS Access 2
S impossibile aprire il volume Windows e Software 0
C Impossibile loggarsi. HTML e CSS 1
S Impossibile scorrere un oggetto in JavaScript Javascript 0
felino [Joomla 1.5] Backend senza toolbar, impossibile eseguire qualunque operazione Joomla 1
felino [Windows 8.1 Pro] Impossibile attivare/avviare Windows Defender Windows e Software 3
W Errore di run-time di Microsoft VBScript error '800a0035' Impossibile trovare il file Classic ASP 0
S PHP Impossibile stabilire la connessione PHP 8
W Impossibile Trovare Provider Classic ASP 7
M Impossibile visionare la immagini dall'App. IP Cam e Videosorveglianza 8
Q impossibile modificare un file ....... C/C++ 2
C Impossibile "entrare" nel IPCAM IP Cam e Videosorveglianza 0
M [Photoshop] impossibile impostare Profilo colori Photoshop 1
Magenta [WordPress] impossibile reinstallare NextGallery in locale WordPress 1
T [PHP] Calcolo anzianità soggetti [era: Help me :( Esercizio per me impossibile] PHP 9
P prestashop - Impossibile raggiungere sito..impiegato troppo tempo a rispondere E-Commerce 0
G Somma variabili impossibile Javascript 3
felino [Backend] Impossibile accedere al backend WordPress 2
A Impossibile accedere alle configurazioni del router Reti LAN e Wireless 1
F Aiuto: impossibile la mappatura di un'immagine con Dreamweaver CC2015 HTML e CSS 8
R Bootstrap Carousel allineamento a sinistra impossibile! HTML e CSS 1
A Gestione completa di una tabella del Database... impossibile PHP 0
M Impossibile accedere a pc su LAN Reti LAN e Wireless 1
R Errore nel CSS impossibile HTML e CSS 2
P Creare un social network in 2 persone: arduo o impossibile? Discussioni Varie 2
asevenx Impossibile connettersi al database - mysql system error: 111 MySQL 3
A impossibile installare sp 1 Windows e Software 0
M Login Admin impossibile V 1.9 Magento 0
Marco_88 Impossibile accedere al database PHP 16
T Impossibile installare ChatWee Joomla 0
C Aggiunta nuovo ruolo utente e impossibile modificare le pagine WordPress 7
P Impossibile selezionare il database PHP 7
P impossibile selezionare il database PHP 0
renoir09 impossibile visualizzare bacheca siti in modalità multisito in locale (mamp) WordPress 0
felino [Virtuemart] Impossibile effettuare alcun modifiche dall'amministrazione Joomla 0
S Impossibile collegarsi al DB... PHP 7
P Impossibile completare immediatamente l'operazione sul socket non a blocchi. PHP 1
P Impossibile usare socket_connect PHP 2
asevenx Problema Dreamweaver "impossibile individuare i file correlati dinamicamente..." e con i <div> HTML e CSS 1
G Aiuto!problema impossibile da risolvere Joomla 1
M Impossibile digitare password da terminale Linux e Software 1
best impossibile accedere Supporto Mr.Webmaster 4
A Favicon sull' Url - Impossibile HTML e CSS 5
renoir09 Impossibile caricare immagini con wordpress WordPress 0
T [MySql] impossibile estrarre dati da campi TEXT MySQL 0
matrobriva Impossibile connettersi al server localhost. PHP 9
borgo italia outlook: impossibile bloccare indirizzo di posta Windows e Software 5
L Paginazione impossibile HTML e CSS 3
neo996sps Impossibile caricare file su di un sito PHP 4
moon Impossibile spostare cartella Windows e Software 6

Discussioni simili