Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Beginning C# 7 Hands-On ?????? The Core Language
Beginning C# 7 Hands-On ?????? The Core Language

Beginning C# 7 Hands-On ?????? The Core Language: Learn the C# language by coding it element by element

eBook
€8.99 €26.99
Paperback
€32.99
Subscription
Free Trial
Renews at €18.99p/m

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Table of content icon View table of contents Preview book icon Preview Book

Beginning C# 7 Hands-On ?????? The Core Language

Why C# and How to Download and Install the Visual Studio Community Edition

If you visit a page like indeed.com and enter C# in the what box, you'll get results that show that there are many jobs in this field, as shown in Figure 1.1.1. This shows that C# is a very valuable skill to master. Perhaps you just like to tinker, and C# is great for that as well:

Figure 1.1.1: The many job listings for C# programmers

Locating and downloading the Visual Studio Community edition

In this chapter, we're going to take a look at how to get Visual Studio 2017. You can either go directly to www.visualstudio.com/downloads or just do a search for Visual Studio 2017 download. This should bring you to a page similar to this one:

Figure 2.1:

Keep in mind that these pages are updated regularly. In the preceding screenshot, you will see that there are several versions. The one that interests us, of course, is Visual Studio Community 2017, the free version.

Click on Free download. This should automatically download a small installer. Depending on how your system is set up, it will either download it directly to the Downloads folder, or prompt you for where you want to save it. I've created a VS_Community folder inside My Downloads folder and saved it there. Of course, you can save it wherever you want to. Once this is done--it won't take long as it's just a small file--locate the downloaded VS_Community.EXE file and open it up.

Once you open it, you should see this screen.

Figure 2.2: The License screen

Click on Continue, which should take you through to the next screen:

Figure 2.3: Choosing download components

From here, you can select the set of features you want to install on your system. For our purposes, I've chosen.NET desktop development at the top. If you click on it, you should see a check mark appear in the top corner to show that it's been selected:

Figure 2.4: Selecting .NET desktop development

Down at the bottom of the window, there's a location bar. If you click on the three little dots, you can select where you want the Visual Studio program to be installed on your system. On the right-hand side, you have a summary field:

Figure 2.5: Selecting the following frameworks

This tells you what's going to be installed; also, down at the bottom, it says Total install size, 3.06 GB, so that's how much minimum free space you need wherever you're going to install this. Then, of course, click on the Install button in the lower right-hand corner. This should bring you to a page similar to this one:

Figure 2.6: Installation in progress

Now, it's just a matter of waiting for everything to be downloaded and then applied to your system. One thing that I recommend you do at this point is temporarily disable your antivirus software while this is being installed because it could interfere with the installation process. I got to about 90 percent and my system hung when I installed it. I went back and disabled my anti-virus software and it installed fine. You may have to do the same.

Once it's downloaded and installed, you should see a screen similar to this one:

Figure 2.7: The Welcome screen

From here on, of course, you can either look at the release notes if you want, or just click on the Launch button. Go ahead and click on the Launch button. This should bring you to a screen similar to this one:

Figure 2.8: The Sign in screen

If you want, you can sign in with your Microsoft account,if you remember. I chose Not now, maybe later. The next step is to choose the interface:

Figure 2.9: Choose color theme

I like the standard Blue one. Of course, you can use the Dark one or the Light one, whichever one you like, and then click on Start Visual Studio. Once it's loaded, it should look very similar to the one that you see right here:

Figure 2.10: Getting Started

Now Go to Help > About Microsoft Visual Studio; you'll see the version that you have installed. Mine is 15.3.0, which is the latest version at the time of this writing. Make sure that yours is the same or above (it should be, as you just downloaded the latest version from Microsoft); otherwise, the code samples that we create will not work because they rely on the features of C# available in this version. Okay, close the About box. That's it! You're now ready to start learning C# 7.

Summary

In this chapter, you learned how to locate, download, install, and launch Visual Studio Community.
In the next chapter, we'll take greater control of Visual Studio and configure it to some extent.

Left arrow icon Right arrow icon

Key benefits

  • • Learn C#, Visual Studio, and Object Oriented Programming,
  • • See practical examples of all the core C# language features so that you can easily master them yourself
  • • Use the C# 7 programming language to work with code and data, which can be applied to other programming languages as well,
  • • Complete a variety of programming assignments for hands-on practice, as you move through the course.

Description

Beginning C# 7 Hands-On - The Core Language teaches you core C# language and syntax in a working Visual Studio environment. This book covers everything from core language through to more advanced features such as object-oriented programming techniques. This book is for C# 7 beginners who need a practical reference to core C# language features. You'll also gain a view of C# 7 through web programming with web forms, so you'll learn HTML, basic CSS, and how to use a variety of controls, such as buttons and drop-down lists. You'll start with the fundamentals of C# and Visual Studio, including defining variables, interacting with users, and understanding data types, data conversions, and constants. You'll move on to checking conditions using if/else blocks, and see how to use loops to do things such as repeat blocks of code. After covering various operators to evaluate and assign control structures, you'll see how to use arrays to store collections of data. By the time you’ve finished the book, you’ll know how to program the vital elements of the core C# language. These are the building blocks that you can then combine to build complex C# programs.

Who is this book for?

This book will appeal to anyone who is interested in learning how to program in C#. Previous programming experience will help you get through the initial sections with ease, although, it’s not mandatory to possess any experience at all.

What you will learn

  • • Learn C#, Visual Studio, and object-oriented programming
  • • Learn all the core C# 7 language syntax with hands-on working examples
  • • Learn everything from basic variable assignments to complex multidimensional arrays
  • • Go through practical examples of all the core C# 7 language features so that you can easily master them yourself
  • • Use the C# programming language to work with code and data, which can be applied to other programming languages as well
Estimated delivery fee Deliver to Switzerland

Standard delivery 10 - 13 business days

€11.95

Premium delivery 3 - 6 business days

€16.95
(Includes tracking information)

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Aug 31, 2017
Length: 566 pages
Edition : 1st
Language : English
ISBN-13 : 9781788296540
Category :
Languages :

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Estimated delivery fee Deliver to Switzerland

Standard delivery 10 - 13 business days

€11.95

Premium delivery 3 - 6 business days

€16.95
(Includes tracking information)

Product Details

Publication date : Aug 31, 2017
Length: 566 pages
Edition : 1st
Language : English
ISBN-13 : 9781788296540
Category :
Languages :

Packt Subscriptions

See our plans and pricing
Modal Close icon
€18.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
€189.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts
€264.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total 98.97
Beginning C# 7 Hands-On ??? Advanced Language Features
€32.99
Learn C# in 7 days
€32.99
Beginning C# 7 Hands-On ?????? The Core Language
€32.99
Total 98.97 Stars icon
Banner background image

Table of Contents

59 Chapters
Why C# and How to Download and Install the Visual Studio Community Edition Chevron down icon Chevron up icon
Customizing Visual Studio to Make it Feel More Personal Chevron down icon Chevron up icon
Creating and Running Your First Page Chevron down icon Chevron up icon
Creating and Running a Page That Incorporates C# Chevron down icon Chevron up icon
Creating and Using a Single Variable Chevron down icon Chevron up icon
String Interpolation and Updating Visual Studio Chevron down icon Chevron up icon
Formatting Output Strings for More Professional Results Chevron down icon Chevron up icon
Using Variables and Data Types Chevron down icon Chevron up icon
Computed Variables and Basic Math Chevron down icon Chevron up icon
Interacting with Users Through the Web Page Chevron down icon Chevron up icon
Using Method Chaining to Write More Compact Code Chevron down icon Chevron up icon
Reacting to a Single Condition with If/Else Blocks Chevron down icon Chevron up icon
Making a Variable Grow by Adding 1 Chevron down icon Chevron up icon
Repeating Blocks of Code with While Loops Chevron down icon Chevron up icon
Repeating Blocks of Code with For Loops Chevron down icon Chevron up icon
Iterating Over Collections with foreach Loops Chevron down icon Chevron up icon
Examining Multiple Variable Values with Switch Blocks Chevron down icon Chevron up icon
Improving Input Processing with TryParse Chevron down icon Chevron up icon
Replacing If/Else Blocks with the Ternary Operator Chevron down icon Chevron up icon
Operators That Evaluate and Assign in Place Chevron down icon Chevron up icon
Checking Two Conditions with the Logical AND Operator Chevron down icon Chevron up icon
Checking Two Conditions with the Logical OR Operator Chevron down icon Chevron up icon
Declaring, Setting, and Reading Arrays Chevron down icon Chevron up icon
Iterating Over Arrays with foreach Loops Chevron down icon Chevron up icon
Creating and Using a Simple Method Chevron down icon Chevron up icon
Passing Arrays into Methods Chevron down icon Chevron up icon
Reference Type and Value Type Variables Chevron down icon Chevron up icon
Creating More Flexible Methods with the params Keyword Chevron down icon Chevron up icon
Creating More Flexible Functions with the out Keyword Chevron down icon Chevron up icon
Combining the ref and out Keywords to Write Flexible Functions Chevron down icon Chevron up icon
The out Keyword in C# 7 Chevron down icon Chevron up icon
Multidimensional Arrays Chevron down icon Chevron up icon
Writing Easier Code with the Var and Dynamic Keywords Chevron down icon Chevron up icon
Creating a Class with a Constructor and a Function Chevron down icon Chevron up icon
Creating a Class with a Static Method Chevron down icon Chevron up icon
Creating a Class with an Object Property Chevron down icon Chevron up icon
Creating a Class with Static Fields, and Properties Chevron down icon Chevron up icon
Centralizing Common Code with Inheritance Chevron down icon Chevron up icon
Centralizing Default Code with Virtual Functions Chevron down icon Chevron up icon
Model Concepts with Abstract Classes Chevron down icon Chevron up icon
Using Custom Types as Return Types Chevron down icon Chevron up icon
Using Lists to Operate on Data Efficiently Chevron down icon Chevron up icon
Writing Less Code with Polymorphism Chevron down icon Chevron up icon
Using Interfaces to Express Common Behaviors Chevron down icon Chevron up icon
Iterating over Instances with Indexers Chevron down icon Chevron up icon
Building Stabler Apps with Exception Handling Chevron down icon Chevron up icon
Using Named and Optional Parameters Chevron down icon Chevron up icon
Using the Null Coalescing Operator to Write Stabler Applications Chevron down icon Chevron up icon
Overloading Operators to Perform Custom Operations Chevron down icon Chevron up icon
Using Enumerations to Represent Named Constants Chevron down icon Chevron up icon
Creating and Using Namespaces Chevron down icon Chevron up icon
Structs, Random Points, and Sleeping Threads Chevron down icon Chevron up icon
Declaring, Creating, and Using Delegates Chevron down icon Chevron up icon
Switch Blocks with when in C# 7.0 Chevron down icon Chevron up icon
Switch Blocks with Objects in C# 7.0 Chevron down icon Chevron up icon
Tuples in C# 7.0 Chevron down icon Chevron up icon
Local functions in C# 7.0 Chevron down icon Chevron up icon
Throwing Exceptions in C# 7.0 Chevron down icon Chevron up icon
Tuples in C# 7.0, Part 2 Chevron down icon Chevron up icon

Customer reviews

Rating distribution
Full star icon Full star icon Empty star icon Empty star icon Empty star icon 2
(2 Ratings)
5 star 0%
4 star 0%
3 star 50%
2 star 0%
1 star 50%
Martin Richard Sanders Nov 14, 2018
Full star icon Full star icon Full star icon Empty star icon Empty star icon 3
I was expecting a book containing a lot of C# syntax, but sadly the book mostly covers building C# apps for the web, so all of the examples are HTML web front end.
Amazon Verified review Amazon
Doggy Daddy May 01, 2019
Full star icon Empty star icon Empty star icon Empty star icon Empty star icon 1
There are several issues with this book. If you are considering buying it, realize that the title itself is deceiving in multiple ways. First, learning the core C# language is not about creating web pages - which is what this book is about. Learning the core elements of a language does not involve web pages or various types of GUI (or visual presentation) forms or such. This book just misses that mark completely. Also, the word "core" has come to mean a totally different thing than how they are using it here. Look it up in Amazon books or just google it. In the .net / C# context, it does not mean "at the heart of" or "central to" as one would think. Bad, deceiving book. Look elsewhere.
Amazon Verified review Amazon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is the delivery time and cost of print book? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela
What is custom duty/charge? Chevron down icon Chevron up icon

Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.

Do I have to pay customs charges for the print book order? Chevron down icon Chevron up icon

The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.

List of EU27 countries: www.gov.uk/eu-eea:

A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.

How do I know my custom duty charges? Chevron down icon Chevron up icon

The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.

For example:

  • If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
  • Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order? Chevron down icon Chevron up icon

Cancellation Policy for Published Printed Books:

You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.

Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.

What is your returns and refunds policy? Chevron down icon Chevron up icon

Return Policy:

We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:

  1. If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
  2. Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
  3. You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
  4. Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
  5. If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
  6. Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.

On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.

What tax is charged? Chevron down icon Chevron up icon

Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.

What payment methods can I use? Chevron down icon Chevron up icon

You can pay with the following card types:

  1. Visa Debit
  2. Visa Credit
  3. MasterCard
  4. PayPal
What is the delivery time and cost of print books? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela