Click here to hide categories Click here to show left categories

User: Home          welcome : Guest          Log In / Register here     




C# interview question: - Partial methods in partial classes of C# and .NET?

Partial methods are important components of partial classes. Read and click on the following link in case you are new to partial classes.

Partial methods helps us to define a method definition in one of the physical files and we can implement that method in the other physical files as shown in the below figure.

In the below figure you can see we have defined “Validate” method in “Customer1.cs” and this validate method is implemented in “Customer2.cs”. Please note the partial keywords attached to both of these methods.

Figure: -

Also see the following video on Partial methods: -

Click for more learning stuffs on C# interview questions

Regards,

Click it for author’s more training stuffs on C# interview questions

Share this article   |    Print    |    Article read by 5387 times
Author:
Shivprasad koirala Koirala
I am a Microsoft MVP for ASP/ASP.NET and currently a CEO of a small E-learning company in India. We are very much active in making training videos , writing books and corporate trainings. Do visit my site http://www.questpond.com for .NET, C# , design pattern , WCF , Silverlight , LINQ , ASP.NET , ADO.NET , Sharepoint , UML , SQL Server training and Interview questions and answers
Related Articles:
Related Interview Questions: