Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the difference between a Sub and a Function?

Answer Posted / mukesh

A function accepts any number of parameters (possibly
zero), does something with them, and returns a value.
A subroutine is performs an action, but doesn't return a
value.

There are two differences between a function and a
subroutine:
A)How they are invoked. B)How they are accessed.

A function call has the following syntax ::function (arg1,
arg2, ...)
where: function -->Is the name of the function. arg1,
arg2, ... Are the arguments.

A subroutine call has the following syntax ::subroutine
(arg1, arg2, ... {outputfield|'format'})
where: subroutine -->Is the name of the subroutine. arg1,
arg2, ... Are the arguments.
{outputfield|'format'} Is the name of the output field or
its format.

In addition, on some platforms, the functions are available
immediately; whereas, the subroutines are available in a
special subroutine library that you must access.

Is This Answer Correct ?    17 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is visual basic case sensitive?

1127


What do you mean by provider?

1929


To.set the command button for ESC ___ Property has to be changed.

1910


Explain about creating VB applications in excel?

1127


What is the latest version of visual basic?

934


It possible to call OLEDB's Features directly in VB without using any control?

2376


How would you create Visual basic Document file?

2632


What is the use of Hyperlink control for DHTML applications?

2182


How would you use ActiveX Dll and ActiveX Exe in your application?

2116


Explain the types of Views in Listview Control?

2249


Which type of object requires this object?

1981


What are the Internet tools available in VB6.0?

2906


___ argument can be used to make a menuitem into bold.

1838


Explain about trees structures work.

1065


What is the use of Data Form Wizard?

1976