Visual Basic 6

What are return types?
I know one type is boolean.
Please give examples of other return types?
chrishaAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

jamaussCommented:
If you are talking about variable types the amount is endless. But among the most used are

Integer
Boolean
Long
Double
String
Currency
Variant
Static

Is that what you are looking for?
0
woottondCommented:
A return type is the type of object returned by a procedure. Therefore a return type could be any object that vb has already defined ie integer, string, char, boolean, long... or some other object that you have defined.
Hope this answers your question,
che,
.././David
0
RuchiCommented:
Return types can be explicitly state in the Function procedure header using either the As keyword or a type declaration character. i.e. you could write the definition of Area to return a single ....

private function area(s1 as single, s2 as single) as single

if using boolean,

 private function test() as boolean.
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

st_steveCommented:
In addition to what jamauss said....."single" is also a variable type...don't know if this is what you want though.....these are variable types
0
st_steveCommented:
In addition to what jamauss said....."single" is also a variable type...don't know if this is what you want though.....these are variable types you can also have "byte" and other things. you can check the declaration of variable types by typing:

(dim "variable_name" as) followed by a space. VB should display all the valid types automatically.

e.g. dim abc as  (notice the space at the end)
0
paul_tsekovCommented:
Hi, VBfan




A return type is the type of the value that some function returns:

Private Function MyFunc(Param1 As Long, Param2 as String, ......) As Boolean

  MyFunc=True
.....
.....
  MyFunc=False
......
......
End Function

The type of the function in this case is Boolean

So if you have the variable
Dim Flag As Boolean

You can write:
  Flag=MyFunc(30024, "John Eagles", ....)

The return value can be any of the types, that Visual Basic supports:

Boolean
Integer
Single
Double
Long
Double
String
Currency
Variant
Static

 and so on...

       Pavel Tsekov
   email : paul_tsekov@yahoo.com
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
RuchiCommented:
Chrisha: Where are you? Please say something so we could be of any help to you.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Development

From novice to tech pro — start learning today.