You are viewing our Forum Archives. To view or take place in current topics click here.
Learn C#|Get Help|Friendly Chat
Posted:
Learn C#|Get Help|Friendly ChatPosted:
Status: Offline
Joined: Jun 24, 201311Year Member
Posts: 50
Reputation Power: 1
Status: Offline
Joined: Jun 24, 201311Year Member
Posts: 50
Reputation Power: 1
-Icon's C# tuts and Help-
I would recommend Ms Visual Studio
Download: [ Register or Signin to view external links. ]
Learn C#
What is c#
C# (pronounced "see sharp" or "C Sharp") is one of many .NET programming languages. It is object-oriented and allows you to build reusable components for a wide variety of application types Microsoft introduced C# on June 26th, 2000 and it became a v1.0 product on Feb 13th 2002.
C# is an evolution of the C and C++ family of languages. However, it borrows features from other programming languages, such as Delphi and Java. If you look at the most basic syntax of both C# and Java, the code looks very similar, but then again, the code looks a lot like C++ too, which is intentional. Developers often ask questions about why C# supports certain features or works in a certain way. The answer is often rooted in it's C++ heritage.
Source
Console is one of the best things to start with!
Starter/Hello World:Lesson:1
What is c#
C# (pronounced "see sharp" or "C Sharp") is one of many .NET programming languages. It is object-oriented and allows you to build reusable components for a wide variety of application types Microsoft introduced C# on June 26th, 2000 and it became a v1.0 product on Feb 13th 2002.
C# is an evolution of the C and C++ family of languages. However, it borrows features from other programming languages, such as Delphi and Java. If you look at the most basic syntax of both C# and Java, the code looks very similar, but then again, the code looks a lot like C++ too, which is intentional. Developers often ask questions about why C# supports certain features or works in a certain way. The answer is often rooted in it's C++ heritage.
Source
http://www.csharp-station.com/
Console is one of the best things to start with!
Starter/Hello World:Lesson:1
using System;
// Program start class
class helloworld
{
// Main begins program!
static void Main()
{
// Write to console
Console.WriteLine("Hello, C# is fun");
// keep screen from going away
Console.ReadLine();
}
}
Starter/Loops Lesson:2
using System;
class Loop
{
public static void Main()
{
int myInt = 0;
while (myInt < 10) //int lessthen 10
{
Console.Write("{0} ", myInt);
myInt++;
}
Console.WriteLine();
}
}
Starter/Classes Lesson:3
// Namespace Declaration
using System;
// helper class
class Classes
{
string myString;
// Constructor
public OutputClass(string inputString)
{
myString = inputString;
}
// Instance Method
public void printString()
{
Console.WriteLine("{0}", myString);
}
// Destructor
~OutputClass()
{
// Some resource cleanup routines
}
}
// Program start class
class ExampleClass
{
// Main begins program execution.
public static void Main()
{
// Instance of OutputClass
OutputClass outCl = new OutputClass("This is printed by the output class.");
// Call Output class' method
outCl.printString();
}
}
More about classes:
[ Register or Signin to view external links. ]
Starter/If/else Lesson:4
using System;
class ifelse
{
public static void Main()
{
int age;
Console.WriteLine("How Old are You?");
age = Console.ReadLine();
if (age < 18)
{
Console.WriteLine("YOU ARE TOO YOUNG!")
Console.Readline();
}
else
{
Console.WriteLine("WELCOME");
Console.ReadLine()
}
}
}
Forms
Starter/Hello World Lesson:1
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace helloworld
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
label1.Text = "Hello"; //sets label1 text to Hello
button1.Text = "Set Name"; //sets button1 text to Set
textBox1.Visible = false; //hides textbox1
}
private void button1_Click(object sender, EventArgs e)
{
button1.Text = "Set";
textBox1.Visible = true; //shows textbox1
label1.Text = "Hello, " + textBox1.Text; //displays name in label1
}
}
}
[ Register or Signin to view external links. ]
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace helloworld
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
label1.Text = "Hello"; //sets label1 text to Hello
button1.Text = "Set Name"; //sets button1 text to Set
textBox1.Visible = false; //hides textbox1
}
private void button1_Click(object sender, EventArgs e)
{
button1.Text = "Set";
textBox1.Visible = true; //shows textbox1
label1.Text = "Hello, " + textBox1.Text; //displays name in label1
}
}
}
[ Register or Signin to view external links. ]
Don't have time to update anymore School is something I need to focus on sorry!
Last edited by -Icon-remix- ; edited 2 times in total
#2. Posted:
Status: Offline
Joined: Jun 24, 201311Year Member
Posts: 50
Reputation Power: 1
Status: Offline
Joined: Jun 24, 201311Year Member
Posts: 50
Reputation Power: 1
If anyone has a request I would love to help you!
- 0useful
- 0not useful
#3. Posted:
Status: Offline
Joined: Dec 08, 20149Year Member
Posts: 48
Reputation Power: 1
Status: Offline
Joined: Dec 08, 20149Year Member
Posts: 48
Reputation Power: 1
You know what would be Better... you Did Videos And text tuts...
Release Projects with source that go Along with your videos
Make Each session Longer
Release Projects with source that go Along with your videos
Make Each session Longer
- 0useful
- 0not useful
#4. Posted:
Status: Offline
Joined: May 05, 201212Year Member
Posts: 271
Reputation Power: 10
Status: Offline
Joined: May 05, 201212Year Member
Posts: 271
Reputation Power: 10
You should probably describe them out of the code, like instead of inside of the code in comment marks, describe them in the forum line.
- 0useful
- 0not useful
You are viewing our Forum Archives. To view or take place in current topics click here.