Showing posts with label Scope of public/private/friend/protected/protected friend. Show all posts
Showing posts with label Scope of public/private/friend/protected/protected friend. Show all posts

Wednesday 18 January 2012

Scope of public/private/friend/protected/protected friend



Scope of public/private/friend/protected/protected friend.

Visual Basic/Visual C#
Public/public All members in all classes and projects.

Private/private Members of the current class only.

Friend/internal All members in the current project.

Protected/protected All members in the current class and in classes derived from this member?s class. Can be used only in member definitions, not for class or module definitions.

Protected Friend/protected internal All members in the current project and all members in classes derived from this member?s class. Can be used only in member definitions, not for class or module definitions.