Latest topics
» Hacxing...
Wed Dec 31, 2008 10:03 pm by Seanshoots

» Smiley Wars! :D
Thu Dec 18, 2008 10:44 pm by Seanshoots

» plzz plzz sign up
Sat Nov 29, 2008 5:59 pm by spikester145

» Bye - Bye
Sat Nov 29, 2008 2:15 pm by spikester145

» i really belived in this site
Fri Nov 28, 2008 5:46 pm by Bob

» Need an Banner
Wed Oct 29, 2008 11:03 pm by Bob

» Over?
Thu Oct 16, 2008 7:51 pm by Seanshoots

» Meet the staff.
Mon Sep 01, 2008 10:29 am by Bob

» GM Applications.
Fri Aug 29, 2008 9:41 pm by Bob

» Guess What. Im Back!!!!!
Sun Aug 24, 2008 1:09 pm by Bob

» Tell me what you think
Sun Aug 24, 2008 1:08 pm by Bob

» Updates!
Sat Aug 23, 2008 6:32 pm by Bob

» The Third
Wed Aug 20, 2008 5:52 pm by Bob

» The Excuse Game!
Mon Aug 18, 2008 6:25 pm by Bob

» the server as died? Oo
Mon Jul 28, 2008 6:18 pm by Bob

Who is online?
In total there is 1 user online :: 0 Registered, 0 Hidden and 1 Guest

None

[ View the whole list ]


Most users ever online was 17 on Mon Jul 16, 2018 9:00 am
Statistics
We have 20 registered users
The newest registered user is alodivivi

Our users have posted a total of 726 messages in 75 subjects
Affiliates
This section is open for advertisments. Email headshotclan9994@aol.com for information.
 
GuestBook
Click here to let us know what you think of are website while you wait to sign up. Also if you have any problems signing up you can ask here. View my Guestbook
Free Guestbooks by Bravenet.com
Counter

Helper 1: Variables.

Go down

Helper 1: Variables.

Post by Seanshoots on Mon Jun 02, 2008 11:15 pm

This is a Important part of Visual Basic; variables are very useful, like defining a name, etc...

Here, we will make an easy-to-understand program that will use variables.
(When is say 'put in this code' dont erase any code that is there, just put it inbetween!)


First, make a standard EXE.
Enlarge the window a bit, too.
(Drag Corner.)
Make a textbox anywhere on the form.
It can be called anything, it doesnt matter.
Now, make a button. Just call it "Message."
*CODE TIME!*
Double click the button, a code window should popup.
In it, type:
--CODE--
Dim message As String
message = text1.text
seanshoots = MsgBox(message, vbOkOnly)

--END CODE--
([CODE] IS NOT WORKING! Fix Please.)
What this is doing, is telling it that the word 'message' means the text in the textbox.
A variable is like calling someone a name, when someone says their name, you know who or what they are.
Example:
clown
Name = Clown
Therefor, when someone says 'Clown', you would refer to that picture.

So, now press F5.
Now, when you type something in the textbox and press the button, it will popup in the messagebox.
Cool, ey? (Im canadian! Smile )


Last edited by Bob on Tue Jun 03, 2008 12:22 am; edited 2 times in total (Reason for editing : COLORZ!)

_________________

~ Seanshoots
avatar
Seanshoots
RandomMS Owner
RandomMS Owner

Number of posts : 210
Age : 23
Location : Vancouver, BC. Go Canada!
Registration date : 2008-05-24

Character sheet
Bob's Field:

View user profile http://seanspsppimping.blogspot.com

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum