[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 322
  • Last Modified:

ASPX CONNECTION STRING - VISUAL WEB DEVELOPER 2005 EXPRESS

I am running an .aspx page on a Windows 2003 Server which was made using Visual Web Developer 2005 Express Edition.  The page has one connection string named "My_ConnectionString", and several SqlDataSource controls using this string.  The string connects to a SQL Server 2000 table on the same server.  Visual Web Developer 2005 Express runs a local server which displays the page, but when running it from another computer on the network, I get the following error:
"Configuration Error", "Parser Error Message: Unrecognized configuration section 'connectionStrings'."
It highlights Line 12 of the web.config file that VWD 2005 Express generates.  This web.config file contains the following:

<?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>
        <add name="My_ConnectionString" connectionString="Data Source=SQLSERVER;Initial Catalog=Book_orders;Integrated Security=True"
            providerName="System.Data.SqlClient" />
    </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.
        -->
        <compilation debug="false" />
        <!--
            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>
        -->
    </system.web>
</configuration>

How can I modify this web.config file so any computer can access and display this aspx page appropriately with IIS?
0
Stormspace
Asked:
Stormspace
1 Solution
 
samtran0331Commented:
Since it's working from inside VisualWebDev and not IIS....I'm guessing IIS isn't properly configured...check IIS and make sure that the aspx page is in a virtual directory that is configured as an application and that the virtual directory is running ASP.Net 2.0....

0

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now