Are there Function Calling in VB 6?
Hi guys,
I have lots of repeated codes in my coding and I wish to make my codes more readable by calling for functions instead of keep repeating them.
Can someone guide me with functions calling in VB 6? Can you guide me with the declaration as well as the syntax in calling for them?
thanks alot guys...
Regards,
Justin
[361 byte] By [
ootnitsuj] at [2007-11-11 8:03:40]

# 1 Re: Are there Function Calling in VB 6?
An example of a function who gives back a boolean is given in this thread:
http://forums.dev-archive.com/showthread.php?p=449010#post449010
Hope this gives you an idea. If you need more examples, let me know.
Just a remark if you want to replace repeating code you need probably subs, procedures and no functions. A function gives back a value and a sub not.
small ex.:
Private Sub CommandButton1_Click()
Startsub
End Sub
Private Sub Startsub()
MsgBox "This sub works great!"
End Sub
Benjamin