SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I just wanna insert a visual webpart inside another, I'm using this tag to register the inserted web part like this:

<%@ Register Src="~/PL/VisualWebPart1/VisualWebPart1UserControl.ascx" TagName="VisualWebPartx" TagPrefix="bassel" %>

after I deploy this sharepoint project, I add the webpart to a page either through the web interface or the designer.

the result is this error message: "/PL/VisualWebPart1/VisualWebPart1UserControl.ascx' is not allowed on this page"

anybody knows the right way to do this?

share|improve this question
up vote 0 down vote accepted

I was able to do this by registering as assembly instead, like this:

<%@ Register assembly="Forum, Version=, Culture=neutral, PublicKeyToken=645bd5a85fdb995f" namespace="Forum.PL.BreadCrump" tagprefix="uc1" %>

this worked fine. but I was wondering if there's another method.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.