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...

Difference between a sub and a function?

Answer Posted / satishdubey

A Sub Procedure is a method will not return a value
A sub procedure will be defined with a Sub keyword
Sub ShowName(ByVal myName As String)
Console.WriteLine (My name is: & myName)
End Sub

A function is a method that will return value(s).
A function will be defined with a Function keyword
Function FindSum(ByVal num1 As Integer, ByVal num2 As
Integer)
As Integer
Dim sum As Integer = num1 + num2
Return sum
End Function

Is This Answer Correct ?    7 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is strong name in .net assembly?

1029


How to send xml file on server using http protocol?

1051


Explain the use of serialization and deserialization?

1135


Define naming convention?

1055


Did vb6 support multi-threading ?

1000


What are the difference between dispose(), close(), exit(), end()? When do we use them?

1072


What are the features of c# which are not present in vb.net?

1157


What are option strict and option explicit?

1420


What is the advantage of using system.text.stringbuilder over system.string?

1178


Explain convert.tostring and i.tostring method?

968


what is difference between web.config and machine.config and where it will be ?

982


What is a literal control?

1060


What is DLL HELL in VB.NET

1058


Name some different types of control?

1020


What is the difference between static or dynamic assemblies?

1067