N
newbie120
Hi all
maybe its just been a long day, but i have a question about call access
modifiers in C#. Consider the following code.
namespace Application
{
private class Class1
{
int i;
}
}
When I try to compile this i get the following error:
"Namespace elements cannot be explicitly declared as private,
protected, or protected internal"
When i make Class1 public i no longer get a compile error. Now correct
me if i'm wrong, but doesn't C# allow me to have private or protected
class structures? Am i missing something?
thanks
maybe its just been a long day, but i have a question about call access
modifiers in C#. Consider the following code.
namespace Application
{
private class Class1
{
int i;
}
}
When I try to compile this i get the following error:
"Namespace elements cannot be explicitly declared as private,
protected, or protected internal"
When i make Class1 public i no longer get a compile error. Now correct
me if i'm wrong, but doesn't C# allow me to have private or protected
class structures? Am i missing something?
thanks