Beginning C# hands-on -- the core language learn the C# language by coding it element by element

A C# 7 beginners guide to the core parts of the C# language! About This Book 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,...

Descripción completa

Detalles Bibliográficos
Otros Autores: Owsiak, Tom, author (author)
Formato: Libro electrónico
Idioma:Inglés
Publicado: Birmingham, England ; Mumbai, [India] : Packt 2017.
Edición:1st edition
Materias:
Ver en Biblioteca Universitat Ramon Llull:https://discovery.url.edu/permalink/34CSUC_URL/1im36ta/alma991009630715806719
Tabla de Contenidos:
  • Cover
  • Title Page
  • Copyright
  • Credits
  • About the Author
  • www.PacktPub.com
  • Customer Feedback
  • Table of Contents
  • Preface
  • Chapter 1: Why C# and How to Download and Install the Visual Studio Community Edition
  • Locating and downloading the Visual Studio Community edition
  • Summary
  • Chapter 2: Customizing Visual Studio to Make it Feel More Personal
  • Customizing Visual Studio
  • Selecting the text editor font and size
  • Selecting the Statement Completion font and size
  • Selecting the Environment font and size
  • Positioning Visual Studio panels
  • Summary
  • Chapter 3: Creating and Running Your First Page
  • Starting a new project in Visual C#
  • Working with Solutions Explorer
  • Adding a document to your browser
  • Working with HTML code in Visual Studio
  • Launching the HTML code
  • Summary
  • Chapter 4: Creating and Running a Page That Incorporates C#
  • Improving your first program
  • Working in the Design view
  • Working in the Source view
  • Adding comments
  • Adding attribute properties
  • Viewing the code in your browser
  • Summary
  • Chapter 5: Creating and Using a Single Variable
  • Setting up Visual C# to deal with a variable
  • Variables represent change
  • Declaring a variable
  • Matching variable types
  • Running the code
  • Appending new text
  • Running the code with the appended text
  • Embedding a line break
  • Summary
  • Chapter 6: String Interpolation and Updating Visual Studio
  • Selecting a NuGet package
  • Installing a NuGet package
  • Printing a variable
  • Summary
  • Chapter 7: Formatting Output Strings for More Professional Results
  • Setting a value and formatting it as currency
  • Rounding the output
  • Formatting a value as a percent
  • Formatting a value as a date
  • Summary
  • Chapter 8: Using Variables and Data Types
  • Setting a page title automatically.
  • Setting a page title so that it can be controlled dynamically
  • Working with a Boolean data type
  • Using the decimal data type to set monetary values
  • Summary
  • Chapter 9: Computed Variables and Basic Math
  • Declaring and setting two variables to signify two different salaries
  • Adding the two salaries
  • Averaging the two salaries
  • Summary
  • Chapter 10: Interacting with Users Through the Web Page
  • Using Toolbox to search for a command
  • Adding an Event Handler
  • Working with string input
  • Converting string input to a numerical value
  • Working with methods
  • Working with the converted numerical value
  • Summary
  • Chapter 11: Using Method Chaining to Write More Compact Code
  • Inserting a text box into the markup
  • Entering your C# code
  • Introducing method chaining
  • Testing your code
  • Summary
  • Chapter 12: Reacting to a Single Condition with If/Else Blocks
  • Adding checkbox to your code
  • Adding a panel statement
  • Testing the checkbox
  • Working with the AutoPostBack property
  • Constructing an if statement
  • Constructing an else statement
  • Testing your code
  • Summary
  • Chapter 13: Making a Variable Grow by Adding 1
  • Growing a variable by one
  • Another way to grow a variable
  • Summary
  • Chapter 14: Repeating Blocks of Code with While Loops
  • Inserting a button
  • Modifying the button
  • Creating a while loop
  • Working with the Math class
  • Running the code
  • Experimenting with the code
  • Summary
  • Chapter 15: Repeating Blocks of Code with For Loops
  • Inserting a button
  • Inserting ListBox
  • Binding in the code
  • Starting a for loop
  • Filling ListBox using the for loop
  • Summary
  • Chapter 16: Iterating Over Collections with foreach Loops
  • Inserting TextBox
  • Inserting a label
  • Relating TextBox with Label
  • Generating a vertical output
  • Removing parts of the code to determine their impact.
  • Summary
  • Chapter 17: Examining Multiple Variable Values with Switch Blocks
  • Inserting DropBox and Label
  • Populating the drop-down list
  • Adding information to display about each drop-down item
  • Replicating cases
  • Running your program
  • Summary
  • Chapter 18: Improving Input Processing with TryParse
  • Inserting a button and a textbox
  • Inserting the label
  • Introducing the TryParse method
  • Using TryParse to convert input into a numerical value
  • Running your program
  • Summary
  • Chapter 19: Replacing If/Else Blocks with the Ternary Operator
  • Inserting two text boxes and a button
  • Creating the interface
  • Combining the ternary operator with TryParse
  • The Boolean power of TryParse
  • Running your program
  • Summary
  • Chapter 20: Operators That Evaluate and Assign in Place
  • Inserting Button and Label
  • Introducing operators
  • Incrementing the value of a variable by 1 with ++
  • Incrementing the value of a variable by 2 with +&amp
  • #61
  • Working with the
  • operator
  • Working with the &amp
  • #61
  • &amp
  • #61
  • operator
  • Summary
  • Chapter 21: Checking Two Conditions with the Logical AND Operator
  • Setting up the project
  • Building your simulation
  • Determining if there is something in the text boxes
  • Displaying the results
  • Summary
  • Chapter 22: Checking Two Conditions with the Logical OR Operator
  • Working with check boxes
  • Introducing the logical || (OR) operator
  • Experimenting with the logical || (OR) operator
  • Summary
  • Chapter 23: Declaring, Setting, and Reading Arrays
  • Setting up the basic interface
  • Creating the array
  • Setting up an index
  • Using arrays to do addition
  • Using arrays to display an average
  • Viewing the page source
  • Summary
  • Chapter 24: Iterating Over Arrays with foreach Loops
  • Setting up the beginning interface
  • Creating an array of strings.
  • Introducing the foreach loop
  • Displaying the results
  • Running the program
  • Summary
  • Chapter 25: Creating and Using a Simple Method
  • Setting up the user interface
  • Creating a method
  • Defining the body of the method
  • Working with the Convert class
  • Increasing the value of a variable with the GetIncreasedValue method
  • Outputting the results
  • Running your program
  • Summary
  • Chapter 26: Passing Arrays into Methods
  • Setting up the user interface
  • Creating the method to find the total of values inside an array
  • Summing up the values
  • Using a foreach loop to grab entries inside the array
  • Adding up the values as the loop operates
  • Returning the value
  • Filling the array
  • Outputting the results
  • Running your program
  • Summary
  • Chapter 27: Reference Type and Value Type Variables
  • Setting up the user interface
  • Reference type versus value type variables
  • Reference type variables
  • Value type variables
  • Summary
  • Chapter 28: Creating More Flexible Methods with the params Keyword
  • Designing the starting markup
  • Creating the product method
  • Using the product method to multiply variables
  • Summary
  • Chapter 29: Creating More Flexible Functions with the out Keyword
  • Setting up the beginning interface
  • Introducing language-integrated queries
  • Using the out parameter
  • Working with the average extension method
  • Working with the var keyword
  • Outputting the results of the Summarize method
  • Running and modifying your program
  • Summary
  • Chapter 30: Combining the ref and out Keywords to Write Flexible Functions
  • Setting up the starting interface
  • Creating the GetValueAndInterest method
  • The ref and out keywords
  • Calculating principle and interest
  • Outputting the results
  • Running your program
  • Summary
  • Chapter 31: The out Keyword in C# 7
  • Creating the program template.
  • Writing the Summarize function
  • Implementing the function
  • Running the program
  • Summary
  • Chapter 32: Multidimensional Arrays
  • Understanding two-dimensional arrays
  • Setting up the initial interface
  • Coding a two-dimensional array
  • Printing out your results
  • Running the program
  • What else can you do?
  • Summary
  • Chapter 33: Writing Easier Code with the Var and Dynamic Keywords
  • Setting up the project
  • Working with the dynamic keyword
  • Working with the var keyword
  • Running the program
  • Summary
  • Chapter 34: Creating a Class with a Constructor and a Function
  • Our initial markup
  • Creating a class
  • Creating the class structure
  • Working with an instance
  • Setting the account balance
  • Displaying the balance using a method
  • Making a bank account object
  • Crunching the numbers
  • Running the program
  • Private versus public
  • Summary
  • Chapter 35: Creating a Class with a Static Method
  • Setting up a simple initial interface
  • Introducing static classes
  • Creating the Reverse method
  • Coding the Reverse method
  • Reversing the array
  • Undoing the reversed string
  • Running the program
  • Summary
  • Chapter 36: Creating a Class with an Object Property
  • Setting up a simple markup page
  • Creating a class
  • Introducing properties
  • Using the Circle class
  • Making a Circle object
  • Summary
  • Chapter 37: Creating a Class with Static Fields, and Properties
  • Setting up the interface for this project
  • Creating the Truck class
  • Counting trucks
  • Closing IS Express (Windows users)
  • Documenting your program
  • Lesson review
  • Summary
  • Chapter 38: Centralizing Common Code with Inheritance
  • Setting up the interface for this lesson
  • Creating the Vehicles class file
  • Introducing instance variables
  • Writing a function to get the make of a vehicle
  • Creating the Truck class file.
  • Creating the sedan class file.