Results 1 to 3 of 3

Thread: ASP.NET Virtual Directory

  1. #1
    Junior Member
    Join Date
    Feb 2008
    Answers
    2

    ASP.NET Virtual Directory

    i've created a virtual directory for my asp.net application that includes an SQL connection. I have given the connection string in web.config file. though the page opens, i get a connection error.

    plz help me out !!


  2. #2
    Contributing Member
    Join Date
    Jun 2007
    Answers
    65

    Re: ASP.NET Virtual Directory

    Amit, could u pls provide the code how r u using connection and what the error u got actually. Then its I'll be able to understand the problem.

    ---V V----
    Regards,
    Vikas Vaidya


  3. #3
    Junior Member
    Join Date
    Feb 2008
    Answers
    2

    Re: ASP.NET Virtual Directory

    Quote Originally Posted by vikasvaidya View Post
    Amit, could u pls provide the code how r u using connection and what the error u got actually. Then its I'll be able to understand the problem.

    ---V V----
    Regards,
    Vikas Vaidya
    first of all i use asp.net 2.0

    i created my connection in web.config


    in form_load of frmLogin.aspx:
    Try
    con = New SqlConnection(ConfigurationManager.AppSettings("conn"))
    con.Open()
    Catch ex As Exception
    Response.Write("Connection Error")
    End Try

    i created a new virtual directory & gave it read & run permissions. then i went to the properties tab of the above created virtual directory & clicked the documents tab. i added frmLogin.aspx & moved it to top.

    in ie:
    the page opend with the error i specified in catch block.



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact