Click here to Skip to main content
16,017,100 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
i want to know how to call class1.cs class
Posted

You need to create an object instance of the class in another class and then you have access to all the public methods.

If you want to call methods of a class directly, you can make those methods static.
 
Share this answer
 
There is no such notion as "calling a class". You always call a method, or a property through reading it or assigning it a value if it has a getter or a setter, respectively. Besides. "class1.cs" cannot be a class. This looks like a C# file name. It also cannot be called. :-)

The question makes no sense at all.

I don't even know what can help you and does any help make sense or not. You really need to understand your own words.

—SA
 
Share this answer
 
v2
Comments
raj_sagoo 2-Sep-11 3:27am    
i have class1.cs in App_Code and i want to use this class property in another place.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900