Sinisterly
Functions. - Printable Version

+- Sinisterly (https://sinister.ly)
+-- Forum: Coding (https://sinister.ly/Forum-Coding)
+--- Forum: Visual Basic & .NET Framework (https://sinister.ly/Forum-Visual-Basic-NET-Framework)
+--- Thread: Functions. (/Thread-Functions)



Functions. - White Charisma - 01-22-2011

i dont get how to add functions for making ie: a logger/crypter

if anyone could help a noob out i'd greatly appreciate it =]


RE: Functions. - 1234hotmaster - 01-22-2011

functions? you mean making a stub and builder or making a keylogger?


RE: Functions. - Coder-san - 01-22-2011

Functions and Subroutines (Subs) are both Procedures.

Difference:
  1. Functions Return a value, whereas Subs do not.
  2. Subs can be Handled, whereas Functions cannot.

Example of a Function:

Code:
Private Function AddFunction(ByVal FirstNum As Integer, ByVal SecondNum As Integer) As Integer Dim VarRtn As Integer = 0 VarRtn = FirstNum + SecondNum Return VarRtn End Function

Usage of this Function:
Code:
TextBox1.Text = AddFunction(2, 4)



Example of a Sub:

Code:
Private Sub AddSub(ByVal FirstNum As Integer, ByVal SecondNum As Integer, ByVal TextResult As TextBox) Dim VarRtn As Integer = 0 VarRtn = FirstNum + SecondNum TextResult.Text = VarRtn End Sub

Usage of this Sub:
Code:
AddSub(2, 4, TextBox1)



RE: Functions. - 1llusion - 01-22-2011

wow thanks Biggrin

just found a whole new universe Tongue


RE: Functions. - White Charisma - 01-22-2011

@1234 like, in a crypter u would need a function for rc4 encryption yeah?

i just dont know where abouts in my code to add the function, or how to add it


RE: Functions. - Coder-san - 01-23-2011

(01-22-2011, 08:50 PM)D1G1T4LM4N_616 Wrote: @1234 like, in a crypter u would need a function for rc4 encryption yeah?

i just dont know where abouts in my code to add the function, or how to add it

It's not a puzzle game ok?
If you want to learn programming you will have to learn programming, practice and of course, read others' post when they answer your question in a thread.