views:

89

answers:

3

Where is .class files are used ?

In C#.net or ASP.net or in VB.net or only in Windows applications or only in web applications or in only console applications

+4  A: 

They are compiled Java classes.

Typically, they are not used in C# or VB.

GvS
Wrong ..i could add .class files in .net projects using right clicking the project and add item option
Not wrong. Right. You can add *any* file to a .net project by using add item. However they won't be used in any meaningful way.
MarkJ
+2  A: 

C# and VB.net doesn't compile down to .class files. That's Java.

sgrassie
Wrong ..i could add .class files in .net projects using right clicking the project and add item option
Not wrong. Right. You can add *any* file to a .net project by using add item. However they won't be used in any meaningful way.
MarkJ
+2  A: 

What you are calling a "class file" is just a file containing a class. Your real question is "what are classes used for".

You will need to learn object-oriented programming to understand the answer. The answer is - they're used for everything.

And, you're not seeing ".class" files. You're seeing .cs files or .vb files, which happen to contain a class.

John Saunders