What is the actual difference between class library and a namespace? I know both are used to group together classes, namespace etc. Can anyone tell in which scenario should I us
The purpose of namespaces is to avoid name collisions. Namespace should be used when your have several hundreds of classes. Other indicator - when your code is used by somebody else and your names may collide with names in the user code.
Other important difference is that class is always a data type. You can define variables with this type. Namespace is not a type. You cannot define vars with the namespace.