Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. User control in seperate folder

User control in seperate folder

Scheduled Pinned Locked Moved ASP.NET
winformsquestion
6 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    ChrisFarrugia
    wrote on last edited by
    #1

    Hi all, I am working on a website in which I have all the user controls placed in a folder called UserControls. Unfortunately these controls cannot reference the master page while other controls that are not in this folder can. Has anyone experienced this? Thanks a lot, Chris Farrugia

    H V N 4 Replies Last reply
    0
    • C ChrisFarrugia

      Hi all, I am working on a website in which I have all the user controls placed in a folder called UserControls. Unfortunately these controls cannot reference the master page while other controls that are not in this folder can. Has anyone experienced this? Thanks a lot, Chris Farrugia

      H Offline
      H Offline
      Herman T Instance
      wrote on last edited by
      #2

      maybe a difference in NameSpace ?

      C 1 Reply Last reply
      0
      • H Herman T Instance

        maybe a difference in NameSpace ?

        C Offline
        C Offline
        ChrisFarrugia
        wrote on last edited by
        #3

        I am not assigning any custom namespaces. Thanks, Chris

        1 Reply Last reply
        0
        • C ChrisFarrugia

          Hi all, I am working on a website in which I have all the user controls placed in a folder called UserControls. Unfortunately these controls cannot reference the master page while other controls that are not in this folder can. Has anyone experienced this? Thanks a lot, Chris Farrugia

          H Offline
          H Offline
          Herman T Instance
          wrote on last edited by
          #4

          do your usercontrols derive from System.Web.UI.Page? Do you send your Page object to the usercontrol? You should be able to retrieve the masterpage in that case.

          1 Reply Last reply
          0
          • C ChrisFarrugia

            Hi all, I am working on a website in which I have all the user controls placed in a folder called UserControls. Unfortunately these controls cannot reference the master page while other controls that are not in this folder can. Has anyone experienced this? Thanks a lot, Chris Farrugia

            V Offline
            V Offline
            Venkatesh Mookkan
            wrote on last edited by
            #5

            ChrisFarrugia wrote:

            Unfortunately these controls cannot reference the master page while other controls that are not in this folder can.

            Did you tried drag-dropping the UserControl into your MasterPage? Is the UserControl is created as new inside the Project itself or added from some other projects?

            Castle Rider My: Website | Yahoo Group | Blog Spot

            1 Reply Last reply
            0
            • C ChrisFarrugia

              Hi all, I am working on a website in which I have all the user controls placed in a folder called UserControls. Unfortunately these controls cannot reference the master page while other controls that are not in this folder can. Has anyone experienced this? Thanks a lot, Chris Farrugia

              N Offline
              N Offline
              n sa vivek
              wrote on last edited by
              #6

              place the controls in the content panel,which in the master page.

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups