
C#
OK... Heres the thing...
I code C#.
I code C# for work, I code C# for fun... I enjoy C# :D
What is C# you ask?
Well, there's a very technical definition here.
My version?
It's a Programming Language that let's you create... Well... Programs :)
Mind you, it can only create programs for Windows (As I couldn't be bothered with Linux Coding, and I HATE Macs... *Hiss*)... But for Windows? Well... It's AWESOME!
In my life of coding, I went from (Non-Decent Programming Languages (Eg: BASIC) left out)
- 1.) Visual Basic - Bleurgh!
- 2.) Delphi - A bit better...
- 3.) C# - OMG! THIS ROCKS!
To run a C# Program, you need Windows. Preferably XP (As Vista, like Macs, suck!), and preferably with Service Pack 2, Downloadable here (266 MB - Link to EXE).
Depending on how advanced the person coding the app, you need either .NET 1.1, .NET 2.0, or .NET 3.0
Download .NET 3.5 here (197MB - Direct Link to EXE (Can be inserted into DL Manager))
For those people who actually want to TRY programming, download:
Visual C# 2008 Express Edition here (894.7 MB - Link to web-page - Scroll down to Offline Install).
C# Examples
Some nifty little things I've learnt over time (Links open in new window)
Send same HTML Mail to all e-mail addresses in a .txt file
Insert Data Into An Access Database
Select Data From An Access Database
You might already be able to code - RIGHT NOW! (Read This!!!)
Ok - Here's the thing...
Most Modern-Day PC's already HAVE the .NET Framework installed!!
Navigate to:
C:\WINDOWS\Microsoft.NET\Framework\
If that directory exist - You're doing well so far!
Now, navigate to "\Framework\v3.5" - Might be a lower number depending on your PC (1.0, 1.1, etc)
Now, navigate to that directory in Command Prompt(Start->Run->cmd),
type "csc.exe" (Without the quotes) and pres enter.
If you get an error similar to " fatal error CS2008: No inputs specified " Then you can start coding!
Whilst keeping the Command Prompt window open, Open up notepad, and type:
using System;
class program
{
public static void Main()
{
Console.WriteLine("Yay! It compiles!");
Console.WriteLine("Enter a word!");
string myWord = Console.ReadLine();
Console.WriteLine("You entered: " + myWord);
Console.WriteLine("Press Enter to quit.");
Console.ReadLine();
}
}
And save it under "C:\myEg.txt", then close notepad.
Now, in the above command window, type the following:
C:\WINDOWS\Microsoft.NET\Framework\v3.5>csc /out:c:\done.exe c:\myEg.txt
(The C:\WINDOWS\Microsoft.NET\Framework\v3.5> should already be there from the earlier navigation)
and press enter.
If you're successful, you'll have a c:\done.exe
Congratulations! You've just created your first C# Program :)
ASP.NET
ASP.NET is a language that let's you create web-pages.
All web-pages are coded using some sort of programming language, be it HTML, PHP, ASP.NET, etc.
The easiest way to see what a page is coded in is to look at what the URL ends in.
Although, it seems Google is an exception to that... -_-
The cool thing about ASP.NET, is that it let's you use C# for all the coding stuff on your site :D
ASP.NET Examples
Some nifty little things i've learnt over time (Links open in new window)
E-Mail From Code - E-mails someone, specifying From, To, Subject, and Text, with multi-line support.
View Source - Displays the source of any web-page.
Mouse Cursor - Changes the Mouse Cursor whilst moved over ANY ASP.NET Control.
ASP
ASP is pretty much a mixture of HTML, and Server-Side scripting language (I use VBScript at work)
ASP Examples
MySQL To Excel - Connects to a MySQL Database and returns the result as an Excel File.
ReeMail - Implementation of a horrifically easy-to-use mail script, with logging info. (RAR Archive)
ASPSqlCount - How to count results from an ASP SQL Query where COUNT isn't possible.
Until I get around to uploading that, here it is:
SQLQuery = "Select someWeirdStuff from someWeirdPlace inner join etc where etcA = etcB"
Const adUseClient = 3
Const adCmdText = &H0001
set theCounter = server.createobject("adodb.recordset")
theCounter.cursorlocation = adUseClient
theCounter.open SQLQuery, Conn, ,, adcmdtext
countResults = theCounter.recordcount
if (countResults > 0) then
doSomething()
end if
Conclusion
And... Well... That seems to be it for now... Will update this page at a later time :)
Need help? Got any questions (At all? Anything? Maybe?) - Ask me here.