I've created a user control as a dll in Expresion Blend following the steps
provided in the help file. I then add that dll to a new Blend project as a
reference and build the project. The user control shows up in my Asset
Library and I'm able to drag it onto the art board with no problems. The
problem is when I build the new project to test it I get an error:
"Build Error: The Project could not be built. Check the results pane for
more details.
The tag 'UserControl1 does ot exist in XML namespace
'clr-namespace:;assembly=ReleasedControlTest'. Line 10 Position 4."
If I try creating the user control directly in the project as a new xaml
file, build the project, it shows up in the Asset Library. I can drag it
onto the art board, hit f5 and it works fine. I've gone over the help files
again and creating a dll seems pretty straight forward. Is there something
I'm missing? I really need this user control as a dll.
Any help or tips would be greatly appreciated.
Kindest regards,
-LT
Of course adjust prefix and namespace as appropriate.
--
Corrado Cavalli [Microsoft .NET MVP-MCP]
UGIdotNET - http://www.ugidotnet.org
Weblog: http://blogs.ugidotnet.org/corrado/
It's doing this in the released version of Blend and the September Preview.
Steps to reproduce:
1. Open Expression Blend.
2. Select New Project.
3. Select WPF Control Library.
4. Set the language to Visual Basic.
5. Click OK.
6. Create a control.
7. Build the project, the user control is created as a .dll in the bin\debug
directory for the project.
8. Create a new WPF application.
9. Add a reference to the .dll you just created.
10. Build the project (not really necessary when using a dll, the user
control shows up in the Asset Library before building the project).
11. From your Asset Library select the Custom Controls tab.
12. Select your user control and drag it out on the art board.
13. Build the project and the following error occurs:
Build Error: The Project could not be built. Check the results pane for
more details.
The tag 'UserControl1 does not exist in XML namespace
'clr-namespace:;assembly=ReleasedControlTest'. Line 10 Position 4."
The error does not occur if you set the language to C# in step 4 above when
building your user control.
This is a bug in Expression Blend.
The only workaround I can think of is to to modify your project file to
include a RootNamespace attribute to the project file:
<RootNamespace>UntitledProject1</RootNamespace>
Hope this helps! Our apologies for the inconvenience .
Thanks,
-Unni
<UserControl>
"LT" <L...@discussions.microsoft.com> wrote in message
news:188F4FB8-9006-4ED7...@microsoft.com...
I tried all imaginable things and there's definitely a problem in Blend 3 Also, if I do a Rebuild, it says I'm missing some references which is completetely false. the project build very perfectly in VS 2008
Really the problem is very easy to reproduce. The problem is when we do a UserControl that we add on a page and do build. Blend 3 seems not able to find the TAG that is really there in fact. Everything is done normally.
Unni Ravindranathan \(MS\) wrote:
Re: user control as a dll in Blend?
13-Nov-07
If you are seeing this bug only with Visual Basic projects, this is a bug in
Blend.
The only workaround I can think of is to to modify your project file to
include a RootNamespace attribute to the project file:
<RootNamespace>UntitledProject1</RootNamespace>
Hope this helps! Our apologies for the inconvenience .
Thanks,
-Unni
<UserControl>
"LT" <L...@discussions.microsoft.com> wrote in message
news:188F4FB8-9006-4ED7...@microsoft.com...
EggHeadCafe - Software Developer Portal of Choice
Add Windows GridView control in WPF dynamically in C#.
http://www.eggheadcafe.com/tutorials/aspnet/ab67a9fa-7fe1-4995-a6e1-bf33de76bd69/add-windows-gridview-cont.aspx