Solved

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

Posted on 2009-04-06
3
560 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
  • 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

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Join & Write a Comment

I use more than 1 computer in my office for various reasons. Multiple keyboards and mice take up more than just extra space, they make working a little more complicated. Using one mouse and keyboard for all of my computers makes life easier. This co…
Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

757 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now