This is a migrated thread and some comments may be shown as answers.

Inheritance of an existing usercontrol

3 Answers 329 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Christie Admin
Top achievements
Rank 1
Christie Admin asked on 23 Mar 2015, 03:04 AM
Hi,

In my solution, in namespace B, I have a project named CustomControls. This project contain 5 customs UserControls based on existing Telerik UserControls.

ie:

public class CustomExpander : RadExpander (no xaml attached to the class)
{
}

When I try to use my customs UserControls in my main project which is in namespace A in the same solution, in my xaml I can add as an example my CustomExpander but all the properties of the RadExpander are not accesssible in the xaml?!?

Thank's
Alain

3 Answers, 1 is accepted

Sort by
0
Kalin
Telerik team
answered on 24 Mar 2015, 09:43 AM
Hi Alain,

You should have referenced the Telerik binaries in both of the projects in order to get it working correctly. So assume this is the issue here - please try adding references to the other project also.

Hope this helps.

Regards,
Kalin
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
0
Christie Admin
Top achievements
Rank 1
answered on 25 Mar 2015, 03:35 AM
Hi Kalin,

referencing the binairies solved the issue. I have another issue since then... In my UserControl, I added in the MergedDictionary  the theme xaml files but my custom control become not visible. If I use a direct Telerik control, the Telerik control are visible.

Thank's
Alain
0
Kalin
Telerik team
answered on 27 Mar 2015, 09:16 AM
Hello Alain,

When using Implicit Styles you also would also need to merge the theme files in the App.xaml of the other project in order to show the custom controls.

Hope this helps.

Regards,
Kalin
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
Tags
General Discussions
Asked by
Christie Admin
Top achievements
Rank 1
Answers by
Kalin
Telerik team
Christie Admin
Top achievements
Rank 1
Share this question
or