Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7923371
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T17:18:07+00:00 2026-06-03T17:18:07+00:00

im working on a asp.net 3.5 app. i am trying to reference a public

  • 0

im working on a asp.net 3.5 app. i am trying to reference a public class in another class, but the IDE can’t find it. In .net 4.0 you can set the namespace of the website. i think i just need to add the namespace reference to point to the public class i’m trying to reference, but can’t figure out what the “root” or “base” namespace is (or where to set it) in 3.5

public class user control:

Public Class dashboard_controls_registration
    Inherits System.Web.UI.UserControl
End Class

My Business Object:

Namespace BusinessLayer
    Public Class BusinessObject
        Public Function MakeControl() as String
             Dim ctl As dashboard_controls_registration = DirectCast(pageHolder.LoadControl("/controls/registration.ascx"), UserControl)
        End Function
    End Class
End Namespace

In the “MakeControl” function in the businesslayer.businessobject im trying to reference the control (a public class):

However, IDE is throwing an error that it’s undefined. I would assume because it’s not in the same namespace?

I would think that if i referenced the “dashboard_controls_registration” class with it’s namespace it would work.. ie:

Dim ctl As namespace.dashboard_controls_registration = DirectCast(pageHolder.LoadControl("/controls/registration.ascx"), UserControl)

but I can’t find a way in 3.5 to define the “root” namespace of the project. IN 4.0 I use this exact code and it works fine.

Thoughts?
Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T17:18:09+00:00Added an answer on June 3, 2026 at 5:18 pm

    I did not set this project up as a web application. Once I did that, it worked fine.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I’m working on trying to port an ASP.NET app from Server 2003 (and IIS6)
I'm trying to get an ASP.NET MVC app working... I should have known it
in my ASP.NET app, I'm trying to add a CSS reference dynamically (with intelligent
I'm working on a asp.net mvc2 app. I have been using jquery to do
I'm working on an ASP.NET/C# app. I have 2 text boxes and I need
I am working on a asp.net web app in visual studio team system 2008
The ASP.NET web app project I'm currently working on is getting slower over time
I'm working in Asp.net and IntelliSense isn't finding the methods in app code. It
I am working on an existing ASP.NET MVC app that started small and has
I am working on a web app in ASP.NET/C# which needs to be scalable

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.