Solved

Problem in deploying the web site developed in visual studio 2005 to local IIS server ?

Posted on 2009-04-06
3
584 Views
Last Modified: 2013-12-12
i am using visual web developer 2005 for design and vb as script language. when i create a web site using vs2005 the project run's correctly  in debugging mode.

when i deploy it to local server and try to open the default.aspx file through browser, it so an error message in browser as shown below..

Server Error in '/ASPSER' Application.
The current identity (NT AUTHORITY\NETWORK SERVICE) does not have write access to 'D:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files'.


if i try the same from client machine's browser it so the error message shown below.

Server Error in '/ASPSER' 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".

<!-- Web.Config Configuration File -->

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

i tryed all the three way's of deploying and i try it by creating web site as local IIS application also.
without using frame work ordinary ASP files are working properly.

here i am using

server : windows 2003 server.
IIS    : IIS 6.0 as local web server.

i don't know if there is any configuration to be done in IIS 6.0 to run aspx files.
otherwise any modification to be done in web.config file.

my application project and error page screen shot has been in the attachment as zip file.


if there's any to help me.
code of Default.aspx
<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Untitled Page</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <table>
            <tr>
                <td style="width: 145px">
                    Monthly investment
                </td>
                <td style="width: 165px">
                    <asp:DropDownList ID="dbMonthlyInve" runat="server" Width="120px">
                    </asp:DropDownList></td>
            </tr>
            <tr>
                <td style="width: 145px">
                    Annual Interset Rate</td>
                <td style="width: 165px">
                    <asp:TextBox ID="txtInterestRate" runat="server"></asp:TextBox></td>
            </tr>
            <tr>
                <td style="width: 145px; height: 26px">
                    Numbers of Years</td>
                <td style="width: 165px; height: 26px">
                    <asp:TextBox ID="txtYears" runat="server"></asp:TextBox></td>
            </tr>
            <tr>
                <td style="width: 145px">
                    Future Value</td>
                <td style="width: 165px">
                    <asp:Label ID="lblFutureValue" runat="server" Width="153px"></asp:Label>
                </td>
            </tr>
            <tr>
                <td style="width: 145px">
                </td>
                <td style="width: 165px">
                </td>
            </tr>
            <tr>
                <td style="width: 145px">
                    &nbsp; &nbsp;&nbsp;<asp:Button ID="btnCalculate" runat="server" Text="Calculate"
                        Width="104px" /></td>
                <td style="width: 165px">
                    &nbsp; &nbsp; &nbsp;&nbsp;
                    <asp:Button ID="btnClear" runat="server" Height="24px" Text="Clear" Width="104px" />
                </td>
            </tr>
        </table>
        <br />
    
    </div>
        <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="Interest Rate is required" ControlToValidate="txtInterestRate" Display="Dynamic"></asp:RequiredFieldValidator>
        <asp:RangeValidator ID="RangeValidator1" runat="server" ErrorMessage="Years must range from 1 to 45"
            Width="166px" ControlToValidate="txtYears" Display="Dynamic" MaximumValue="45" MinimumValue="1" Type="Integer"></asp:RangeValidator>
        <br />
        <asp:RangeValidator ID="RangeValidator2" runat="server" ControlToValidate="txtInterestRate"
            Display="Dynamic" ErrorMessage="Interest rate must range from 1 to 20" MaximumValue="20"
            MinimumValue="1" Type="Double" Width="141px"></asp:RangeValidator>
        <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txtYears"
            Display="Dynamic" ErrorMessage="Number of year is required"></asp:RequiredFieldValidator>
    </form>
</body>
</html>
 
 
code of Default.aspx.vb
Partial Class _Default
    Inherits System.Web.UI.Page
 
    Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
        If Not IsPostBack Then
            Dim iIndex As Integer
            For iIndex = 50 To 500 Step 50
                dbMonthlyInve.Items.Add(iIndex)
            Next
        End If
 
    End Sub
 
    Protected Sub btnCalculate_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnCalculate.Click
        Dim mMonths As Integer
        Dim mInterstRate, mMonthInves, mFutureValue As Decimal
 
        If IsValid Then
            mMonths = txtYears.Text * 12
            mInterstRate = txtInterestRate.Text / 12 / 100
            mMonthInves = dbMonthlyInve.SelectedValue
            mFutureValue = FutureValue(mMonths, mInterstRate, mMonthInves)
            lblFutureValue.Text = FormatCurrency(mFutureValue)
        End If
    End Sub
 
    Private Function FutureValue(ByVal Months As Integer, _
                                  ByVal InterestRate As Decimal, _
                                  ByVal MonthlyInve As Decimal) As Decimal
        Dim mIndex As Integer
        Dim mFValue As Decimal
        For mIndex = 1 To Months
            mFValue = (mFValue + MonthlyInve) * (1 + InterestRate)
        Next
        Return mFValue
    End Function
 
    Protected Sub btnClear_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles btnClear.Click
        dbMonthlyInve.Text = 50
        txtInterestRate.Text = ""
        txtYears.Text = ""
        lblFutureValue.Text = ""
    End Sub
End Class
 
code of web.config
 
<?xml version="1.0"?>
<!-- 
    Note: As an alternative to hand editing this file you can use the 
    web admin tool to configure settings for your application. Use
    the Website->Asp.Net Configuration option in Visual Studio.
    A full list of settings and comments can be found in 
    machine.config.comments usually located in 
    \Windows\Microsoft.Net\Framework\v2.x\Config 
-->
<configuration>
	<appSettings/>
	<connectionStrings/>
	<system.web>
		<!-- 
            Set compilation debug="true" to insert debugging 
            symbols into the compiled page. Because this 
            affects performance, set this value to true only 
            during development.
 
            Visual Basic options:
            Set strict="true" to disallow all data type conversions 
            where data loss can occur. 
            Set explicit="true" to force declaration of all variables.
        -->
		<compilation debug="true" strict="false" explicit="true"/>
		<pages>
			<namespaces>
				<clear/>
				<add namespace="System"/>
				<add namespace="System.Collections"/>
				<add namespace="System.Collections.Specialized"/>
				<add namespace="System.Configuration"/>
				<add namespace="System.Text"/>
				<add namespace="System.Text.RegularExpressions"/>
				<add namespace="System.Web"/>
				<add namespace="System.Web.Caching"/>
				<add namespace="System.Web.SessionState"/>
				<add namespace="System.Web.Security"/>
				<add namespace="System.Web.Profile"/>
				<add namespace="System.Web.UI"/>
				<add namespace="System.Web.UI.WebControls"/>
				<add namespace="System.Web.UI.WebControls.WebParts"/>
				<add namespace="System.Web.UI.HtmlControls"/>
			</namespaces>
		</pages>
		<!--
            The <authentication> section enables configuration 
            of the security authentication mode used by 
            ASP.NET to identify an incoming user. 
        -->
		<authentication mode="Windows"/>
		<!--
            The <customErrors> section enables configuration 
            of what to do if/when an unhandled error occurs 
            during the execution of a request. Specifically, 
            it enables developers to configure html error pages 
            to be displayed in place of a error stack trace.
 
        <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
            <error statusCode="403" redirect="NoAccess.htm" />
            <error statusCode="404" redirect="FileNotFound.htm" />
        </customErrors>       
        -->
 
            
     <anonymousIdentification enabled="true" />
             
    
	</system.web>
</configuration>

Open in new window

0
Comment
Question by:giitshiva
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 11

Expert Comment

by:b_levitt
ID: 24081412
Start with this part of the error:
"Server Error in '/ASPSER' Application.
The current identity (NT AUTHORITY\NETWORK SERVICE) does not have write access to 'D:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files'.
"

Browse to that folder and make sure the network service account has write permission.
0
 

Author Comment

by:giitshiva
ID: 24084046
yes the  'D:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files'. this folder is set to read only. when tryed to change it attribute to not read only, it itself again set tot Read only attribute. i don't know where to change to write property.

the error page of the browser has been attached
error-Server.JPG
error-Client.JPG
0
 
LVL 11

Accepted Solution

by:
b_levitt earned 250 total points
ID: 24089498
The read-only bit on folders doesn't do anything.  You need to give this specific user write permission to the folder.  Right click the folder --> properties --> Security tab.
0

Featured Post

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Color can increase conversions, create feelings of warmth or even incite people to get behind a cause. If you want your website to really impact site visitors, then it is vital to consider the impact color has on them.
Does your audience prefer people in photos or no people? How can you best highlight what you’re selling? What are your competitors doing, and what can you do that is different and unique from them?  Continue reading to learn how to make your images …
XMind Plus helps organize all details/aspects of any project from large to small in an orderly and concise manner. If you are working on a complex project, use this micro tutorial to show you how to make a basic flow chart. The software is free when…
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question