Go Back   Horror.com Forums - Talk about horror. > Horror.com Lobby > Horror.com General Forum
Register FAQ Community Calendar

Reply
 
Thread Tools
  #1  
Old 11-20-2006, 12:43 PM
Vodstok's Avatar
Vodstok Vodstok is offline
Fear scented candle
 
Join Date: Jan 2004
Location: The edge of forever
Posts: 13,650
Free programming lessons

Okay, i got a bug up my butt and decided to give a little bit of insight into my professional life. So, for anyone who is interested, i am going to show how to make some simple programs in C# (C-sharp), my language of choice.

for starters, you will need the .net framework. I prefer the 2.0 framework, as it is the latest and greatest, and is required to use Visual Studio express (more on that in a second)
http://www.microsoft.com/downloads/d...displaylang=en

this is the link to get Visual C# express:
http://go.microsoft.com/fwlink/?Link...11&clcid=0x409


you may need a .net passport. Sign up and get one if you dont already have one. Dont worry, Microsoft could care less about you, so its not like they are going to own your soul for signing up.

Install them both, the framework first. Once you have that, we will move on to our first lesson.
__________________
Some misguided people decided I was funny enough to pay. See if they're right:
http://www.cracked.com/members/Vodstok/
(I tweet pretty hardcore, too)
Reply With Quote
  #2  
Old 11-20-2006, 12:56 PM
Vodstok's Avatar
Vodstok Vodstok is offline
Fear scented candle
 
Join Date: Jan 2004
Location: The edge of forever
Posts: 13,650
fire up visual studio (from here on to be called "VCS" for "Visual C# Studio"). complete any config wizards it has. Register it to avoid getting hounded every time you open it.

first off, we are going to start a project.

on the start page, click "Project..." after "Create"

By default, it should have "Windows Application" selected. in the "Name" line, type "Lesson1", then hit "OK". this will make a new programproject called "Lesson1". (crazy how that works....)

VCS will create some fun little files for you, and the main window will have an ugly little box that says "Form 1". you should have a menu that says "Toolbox". In Toolbox, there will be an area called "Common Controls". click on "Button". now click on the ugly little "Form 1". See? There's a button now!


Double-click the button. Dont be scared. this is where you program. you will see something that looks like this:
private void button1_Click(object sender, EventArgs e)
{

}

Make it look like this:

private void button1_Click(object sender, EventArgs e)
{
MessageBox.Show("YOU CLICKED A BUTTON!");
}

NOTE: C# is case sensitive, so ANYTHING not inside quotation marks (in this case, anyhing NOT "YOU CLICKED A BUTTON!") HAS to be typed as I have shown.

Did that? Good. now hit "Ctrl-f5" on your keyboard. This will compile and launch your program.

When the new ugly little window pops up, click the button. YAY! see? You just wrote a verrry simple program. Pat yourself on the back.

close your little program and go back to VCS. hit ctrl-shift-S. A save dialogue will come up. just hit "save". This way, your project will still be there if your computer suddenly reboots.
__________________
Some misguided people decided I was funny enough to pay. See if they're right:
http://www.cracked.com/members/Vodstok/
(I tweet pretty hardcore, too)

Last edited by Vodstok; 11-20-2006 at 12:58 PM.
Reply With Quote
  #3  
Old 11-21-2006, 04:36 AM
Vodstok's Avatar
Vodstok Vodstok is offline
Fear scented candle
 
Join Date: Jan 2004
Location: The edge of forever
Posts: 13,650
Any interest in this, or should i just let it die?
__________________
Some misguided people decided I was funny enough to pay. See if they're right:
http://www.cracked.com/members/Vodstok/
(I tweet pretty hardcore, too)
Reply With Quote
  #4  
Old 11-21-2006, 07:18 AM
VampiricClown VampiricClown is offline
Evil Dead
 
Join Date: Nov 2005
Posts: 7,043
I'm interested in it. I can't start on it today, but possibly tomorrow...
Reply With Quote
  #5  
Old 11-21-2006, 07:26 AM
Vodstok's Avatar
Vodstok Vodstok is offline
Fear scented candle
 
Join Date: Jan 2004
Location: The edge of forever
Posts: 13,650
I will probably keep posting little lessons even if i get no feedback. I figure its a nice way to get some exposure for people who are curious but dont know where to look.
__________________
Some misguided people decided I was funny enough to pay. See if they're right:
http://www.cracked.com/members/Vodstok/
(I tweet pretty hardcore, too)
Reply With Quote
  #6  
Old 11-21-2006, 08:53 AM
Phalanx Phalanx is offline
Evil Dead
 
Join Date: Aug 2006
Posts: 3,677
The chick might take you up on it, man...me, I get annoyed with spreadsheets.
Nice idea though.
__________________
It's not the bullet with your name on it you have to worry about...it's all those other ones marked
"to whom it may concern."
Reply With Quote
  #7  
Old 11-21-2006, 09:42 AM
stygianwitch's Avatar
stygianwitch stygianwitch is offline
I ain't afraid'a no ghost
 
Join Date: Jul 2006
Location: I'm here, where are you?
Posts: 2,091
Send a message via MSN to stygianwitch
i'll be giving it a go too, but expect pm's when i don't understand wtf it all means... i'm one of these weird people who have to understand what the instuction will do not just see the end result, so keep ya inbox cleared ;)
__________________
Don't mess with me or I'll rip your arms off and beat you to death with the soggy end

DVD
Reply With Quote
  #8  
Old 11-21-2006, 10:14 AM
Vodstok's Avatar
Vodstok Vodstok is offline
Fear scented candle
 
Join Date: Jan 2004
Location: The edge of forever
Posts: 13,650
Quote:
Originally Posted by stygianwitch View Post
i'll be giving it a go too, but expect pm's when i don't understand wtf it all means... i'm one of these weird people who have to understand what the instuction will do not just see the end result, so keep ya inbox cleared ;)
PM if oyu want, but asking questions publically would be a good idea so that everyone can benefit from the explanation :D
__________________
Some misguided people decided I was funny enough to pay. See if they're right:
http://www.cracked.com/members/Vodstok/
(I tweet pretty hardcore, too)
Reply With Quote
  #9  
Old 11-21-2006, 10:16 AM
stubbornforgey's Avatar
stubbornforgey stubbornforgey is offline
my opinion counts dammit
 
Join Date: Oct 2005
Location: in my lords pocket
Posts: 6,485
Send a message via MSN to stubbornforgey Send a message via Yahoo to stubbornforgey
shit!!
FINALLY..a good thread..nice vodstock..
ppl may not be replying but they are taking notes.
__________________
my opinion counts dammit
so says my Lord :D
Reply With Quote
  #10  
Old 11-21-2006, 10:17 AM
stygianwitch's Avatar
stygianwitch stygianwitch is offline
I ain't afraid'a no ghost
 
Join Date: Jul 2006
Location: I'm here, where are you?
Posts: 2,091
Send a message via MSN to stygianwitch
Quote:
Originally Posted by Vodstok View Post
PM if oyu want, but asking questions publically would be a good idea so that everyone can benefit from the explanation :D
you got a deal, but be warned i can be a real pain in the ass til i understand :o
__________________
Don't mess with me or I'll rip your arms off and beat you to death with the soggy end

DVD
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 03:10 PM.