Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to change the access modifier of a user control

I have a user control created in xaml, lets name it "View". In the View.xaml.cs I changed the access modifier for the class View to internal:

internal partial class View : ViewBase { ... }

After changing the access modifier the compiler states the error:

Partial declarations of 'A.B.View' have conflicting accessibility modifiers

My first guess was that the view has to be made internal via the xaml code. So I added two lines of xaml:

x:Name="View"
x:FieldModifier="internal"

But this did not fix the error. Where do I have to change the access modifier to make a view internal?

like image 515
PVitt Avatar asked Oct 18 '10 08:10

PVitt


1 Answers

The class modifier is done through "x:ClassModifier".

See http://msdn.microsoft.com/en-us/library/ms754029.aspx for more information.

like image 127
Pieter van Ginkel Avatar answered Sep 28 '22 17:09

Pieter van Ginkel