Presentation is loading. Please wait.

Presentation is loading. Please wait.

CPSC 481 Fateme Rajabiyazdi #W4. Visual Studio Download Visual Studio 2013 (Ultimate) from – MSDN Academic Alliance Software Center – IT email account.

Similar presentations


Presentation on theme: "CPSC 481 Fateme Rajabiyazdi #W4. Visual Studio Download Visual Studio 2013 (Ultimate) from – MSDN Academic Alliance Software Center – IT email account."— Presentation transcript:

1 CPSC 481 Fateme Rajabiyazdi #W4

2 Visual Studio Download Visual Studio 2013 (Ultimate) from – MSDN Academic Alliance Software Center – IT email account If you don’t have one, go to CPSC help desk and ask Or email help desk, help@cpsc.ucalgary.ca

3 Source Control Team Foundation Server http://www.visualstudio.com/en- us/products/tfs-overview-vs.aspx Git

4 Starting a New Project

5 Click on File->New->Project

6 Click on Visual C# -> Console Application

7 The Workspace

8 Hello Word! Hint: Use Console. Inside your main function

9 using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleTest { class Program { static void Main(string[] args) { Console.WriteLine("Hello World"); }

10 BreakPoint : F9

11 Debugging - Watch

12 Naming Variables CamelCasing for variables – int MyInteger PascalCasing for methods – Public void HelloWorld(){…};

13 Interfaces start with I A good reference: http://www.csharpfriends.com/articles/getarticl e.aspx?articleid=336

14 Commenting // Single line /* Multi line */ /// This is how you describe methods

15 Access Public: accessible anywhere Private: only accessible within the class Protected: only accessible within the same hierarchy

16 Properties Members that provide a mechanism to read, write or compute the values of private fields They expose a public way of getting and setting values, while hiding implementation. The Keyboard value defines the value being set Properties without a set are read-only

17 Class TimePeriod { private double seconds; public double Hours{ get {return seconds/3600;} public set { seconds = value *3600;} }

18 Others… Class in C# are private by default Booleans are “bool” Instead of ArrayList, we have List List.length -> list.Count


Download ppt "CPSC 481 Fateme Rajabiyazdi #W4. Visual Studio Download Visual Studio 2013 (Ultimate) from – MSDN Academic Alliance Software Center – IT email account."

Similar presentations


Ads by Google