web.config info needed

Discussion in 'ASP.NET / ASP.NET Core' started by ParkerShannon, Jan 3, 2009.

  1. I have a database on SQL Server 2008 and I have a web on SQL Server 2005. Am using Expression as a web editor.

    I know I have established a connection between my database and Expression Design. I have tested the connection and it's fine.

    During the definition or configuration of a Data ASP Control -- DataList for example -- there is an option to test the formatted query in Expression and I can see the data in my table. So I am communicating with the database from an Expression Design View ASPX page.

    When I "File/Preview in Browser," I get this error message:

    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".





    Code:
    <!-- Web.Config Configuration File -->
    
    <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.





    Code:
    <!-- Web.Config Configuration File -->
    
    <configuration>
        <system.web>
            <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
        </system.web>
    </configuration>

    I have tried to make my web.config file as simple as possible. Here it is:





    <configuration>

    <connectionStrings>
    <add name="SQL Connection" connectionString="Data Source=sql2k801.discountasp.net;Initial Catalog=SQL2008_479967_dbobama;Persist Security Info=True;User ID=SQL2008_479967_dbobama_user;Password=obama08"
    providerName="System.Data.SqlClient" />
    </connectionStrings>

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

    </configuration>


    Anybody got any ideas on how to get me out of this hell?

    Back to Top
     
  2. Hi,
    If that's your password edit it quick with comments i.e. *******
    I'd suggest implementing Add and Remove sections for your conn string, add an additional section for SQL Express, even though your site is not using it.

    Like this:
     
  3. It's a bogus password and I will try your suggestion.

    Thank you . . .
     

Share This Page