Friday, July 16, 2010

Two Main() function in an application?

Is it possible to have two Main() function in a program?

1 comment:

Lakshmi said...

Yes, we can have a two entry points in one application. But at a time we can run only one Main () Fun.
By using properties of application we can set which main needs to run.

Steps to set the Main():

RightClick on project -> properties -> application -> startup object. (Set startup object as the required main fun).