CSE 325: .NET Software Development

01 Assignment: Build .NET Applications with C#

Overview

The objective is to briefly review C# syntax, introduce .NET, create a .NET project working with dependencies, debug, and create a web API with ASP.NET core controllers that implement basic CRUD logic.

The content of this module comes from the learn.microsoft.com learning path content.

Instructions

  1. Complete the following "Build .NET Applications with C#" Microsoft learning modules in the order provided.
    Optional: If you establish a free profile account with Microsoft, your learn.microsoft.com progress will be tracked and you can earn badges and experience points (XP) as you work through any of their tutorials and challenges.
    ☑️ Stay organized and create a new repository for each assignment in your Azure DevOps cse325 Project space so that you have a copy and can share your work with your peers and the instructor.
    1. Write your first C# code – Get started by writing code examples to review the basics of the C# syntax.
      Need to spend more time refreshing with the C# programming language?
      Consider these C# refreshers modules.
    2. Introduction to .NET – Start learning about .NET. Understand what .NET is and how it works, and quickly build a small app in a web-based .NET environment.
    3. Create a new .NET project and work with dependencies – Use dependencies from the NuGet registry to develop .NET applications faster. Learn how to manage dependencies for your project.
    4. Interactively debug .NET apps with the Visual Studio Code debugger – Learn how to efficiently debug your .NET app by using Visual Studio Code to fix your bugs quickly.
    5. Work with files and directories in a .NET app – Build an app that manipulates files and directories with C# and .NET.
    6. Create a web API with ASP.NET Core controllers – Create a RESTful service with ASP.NET Core controllers that supports create, read, update, delete (CRUD) operations.
    7. Add at least one additional record to the Create a web API with ASP.NET Core controllers module in the Pizzas List.
  2. Add an additional function to the Work with files and directories in a .NET app module that generates a sales summary report file. The file should contain simple text that shows the actual sales total from the file and a detailed report of each the total sales.
    Here is an example:
    Sales Summary
    ----------------------------
     Total Sales: $x,xxx,xxx.xx
    
     Details:
      filename: $xxx,xxx.xx
      filename: $xxx,xxx.xx
      ... etc.
    

    Using a StringBuilder object to build the report is OK.
    Remember that in C# you can format numbers as currency with the ToString("C") or string interpolation var:C method.

Submission

  1. Create a document (.docx or .txt file) that contains the following two items:
    1. A copy of the output from the end of the module Create a web API with ASP.NET Core controllers showing the existing content and your additional record.
    2. A text copy of your working sales summary function for Part 2.
It is recommended that you keep each assignment in a folder on your computer. This will help you keep track of your work and make it easier to submit your work to the correct assignment in Canvas and to store your work on a Azure DevOps cse325