1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

how to run aspx file ?

Discussion in 'C#' started by kharearch, Jul 11, 2008.

  1. #1
    I am a new user. First time I am placing my files on the server. I am placing default.aspx file on the server. Do I need to place configuration file and default.aspx.vb file also. Please help me. Thanks.
     
    kharearch, Jul 11, 2008 IP
  2. itcn

    itcn Well-Known Member

    Messages:
    795
    Likes Received:
    31
    Best Answers:
    0
    Trophy Points:
    118
    #2
    It depends on how you programmed the page. An aspx page can contain all the .NET code within it inside <script runat="server"> tags, or it can use a codebehind page like default.aspx.vb, which keeps the code separate from the presentation layer. The web.config file is needed to define certain parameters for the website. Without seeing your code, I don't know which ones you need.
     
    itcn, Jul 11, 2008 IP
  3. kharearch

    kharearch Member

    Messages:
    82
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    41
    #3
    I have uploaded all the files including config file. It is giving following error. Please help me to solve this error


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


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


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

    <configuration>
    <system.web>
    <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>
    </system.web>
    </configuration>
     
    kharearch, Jul 12, 2008 IP
  4. itcn

    itcn Well-Known Member

    Messages:
    795
    Likes Received:
    31
    Best Answers:
    0
    Trophy Points:
    118
    #4
    First of all, to find out what error you are getting, simply do what the message says. Add this to your web.config file:

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

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

    By turning off custom errors you will be able to see the details of what is causing the error.
     
    itcn, Jul 12, 2008 IP