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

  • SEARCH
  • Home
  • 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 3667362
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T01:59:27+00:00 2026-05-19T01:59:27+00:00

I have a series of dynamically created GridViews that I load. Everything works fine

  • 0

I have a series of dynamically created GridViews that I load. Everything works fine except when the row details are expanded I get an error “Cannot create unknown type ‘{clr-namespace:EMR.Controls.HPI}HPIDialogButton’. The namespace EMR.Controls.HPI is in the executing assembly and I can use the exact same XAML other places and it works without problems. If I comment out the line ‘hpi:HPIDialogButton…’ then the row details expand without problems.

It seems at the loading point there is some connection missing that is created for you if you do things directly.

   private RadGridView BuildSectionGrid()
    {
      //This is defined here until a better solution is found
      string XAML = @"
          <my:RadGridView IsReadOnly=""False"">
            <my:RadGridView.Columns>
                <telerik:GridViewToggleRowDetailsColumn />
                <telerik:GridViewDataColumn Header=""Selected"" DataMemberBinding=""{Binding IsSelected}"" IsReadOnly=""False""/>
                <telerik:GridViewDataColumn Header=""Definition"" DataMemberBinding=""{Binding Definition}"" IsReadOnly=""True""/>
            </my:RadGridView.Columns>

            <my:RadGridView.RowDetailsTemplate>
                <DataTemplate>
                    <DockPanel Margin=""10"">
                        <Label Content=""Progress Note:"" DockPanel.Dock=""Left""/>
                        <hpi:HPIDialogButton Margin=""5 0 0 0"" DockPanel.Dock=""Right"" HPIText=""{Binding ElementName=NoteItemTextBox, Path=Text, Mode=TwoWay}""/>
                        <TextBox Name=""NoteItemTextBox"" Margin=""5 0 0 0"" DockPanel.Dock=""Left"" AcceptsReturn=""True"" TextWrapping=""Wrap"" Height=""100"" Text=""{Binding ProgressNote}""/>
                    </DockPanel>
                </DataTemplate>
            </my:RadGridView.RowDetailsTemplate>
        </my:RadGridView>
";


      //Load the XAML in again
      ParserContext Context = new ParserContext();
      Context.XmlnsDictionary.Add("", "http://schemas.microsoft.com/winfx/2006/xaml/presentation");
      Context.XmlnsDictionary.Add("x", "http://schemas.microsoft.com/winfx/2006/xaml");
      Context.XmlnsDictionary.Add("mc", "http://schemas.openxmlformats.org/markup-compatibility/2006");
      Context.XmlnsDictionary.Add("telerik", "http://schemas.telerik.com/2008/xaml/presentation");
      Context.XmlnsDictionary.Add("hpi", "clr-namespace:EMR.Controls.HPI");
      Context.XmlnsDictionary.Add("my", "clr-namespace:EMR.Shared.Controls.WPF;assembly=EMR.Shared.Controls.WPF");
      return (RadGridView)XamlReader.Parse(XAML, Context);
    }
  • 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-05-19T01:59:28+00:00Added an answer on May 19, 2026 at 1:59 am

    Try to specify assembly in all your xmlns (you miss it in one):

    Context.XmlnsDictionary.Add(“hpi”, “clr-namespace:EMR.Controls.HPI;assembly=EMR.Controls.HPI”);

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

Sidebar

Related Questions

I have a form field (a series of checkboxes) that's being created dynamically from
I have a series of dynamically generated inputs that I need to have ajax
I have a series of images that get loaded for a carousel, and it
I have a series of chained selects that are populated dynamically by a call
I have a series of select dropboxes setup, with content that dynamically updates depending
I have to dynamically create series of links that when clicked - change some
I have had problems getting Bootstrap popovers working with dynamically created elements (but that's
I have a form that is dynamically created. It is a winForms application. This
I have a series of fields created dynamically based on database records. They will
I have a series of logging breakpoints in Xcode4 that I'm using to selectively

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.