.NET Core tutorials – Hello world with .NET Core


To check if dotnet is correctly installed in your system, please, run command line prompt and type:

dotnet -help

and press enter.

If the command runs, you see a dotnet command options. In case the command fails, download dotnet core sdk or install Visual Studio 2019 with dotnet core framework.

Now:

dotnet new webApp -o myWebApp --no-https
cd myWebApp

dotnet new creates a new application.

  • webApp parameter selects dotnet application type template.
  • -o parameter creates a directory named myWebApp  for the app.
  • --no-https specifies not to enable HTTPS.

In the myWebApp directory you have a simple web application that is ready to run.

  • Startup.cs contains all the settings and configurations.
  • The myWebApp/Pages directory contains some example web pages for the application.
  • myWebApp.csproj defines what libraries are referenced etc.

Now, your app is ready to run, so, please run this command inside app directory:

dotnet run

Once command complete navigate to:

http://localhost:5000

To change page content, open index.cshtml on Pages directory with any text editor y copy this code:

@page
@model IndexModel
@{
ViewData["Title"] = "This is the index page";
}
Hello, world! this is my first dotnet core web app!

Save the file and reload the page.

GOTO next step “.NET Core Tutorials – Razor Pages – Creating a web project”

GOTO topic index

About the author:

Matías Creimerman

Matías Creimerman
I’m a specialist in design, development and management of software solutions with almost 20 years of experience. Microsoft Certificated Professional (MCP). Expert in dot net and Microsoft technologies. Experience and skills in designing solutions in a wide range of commercial, industrial and production areas. Design of architectures, software applications and processes. Skills in leadership and team management. Tech trainer. Technology researcher. Self-taught and dedicated to continuous learning. Skills in estimation, quotation, projects proposals and solutions design. Entrepreneurial spirit. Strong Tech profile but also customer oriented. I perform roles as fullstack dev, tech consultant, technical referent, development leader, team leader, architect, cross leader, tech manager, tech director, trainer, ramp-up & follow-up teams, software factory manager, DevOps and release manager. Regular chess player and musician.

Professional Website

In

Blogger

Github

About Me

Portfolio

Wordpress - Arquitectura y desarrollo de software

Wordpress - Personal Blog

Microsoft - Youracclaim Badges

Microsoft - Tech Profile

Microsoft - ASP.NET Forum

tw
Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License
Creative Commons License
This content is property of Matias Creimerman Any misuse of this material will be punishable
This work is licensed under a International Copyright Law protects “original works of authorship”
including photographs, videos, and blog posts posted on social media sites
The content has no rights to be shared without authorization or citation to the author.
This content cannot be sold be adapted or modified partially or totally.
All content shared outside this blog that doesn’t belong to the author must have citations to the author.

Publicado por:

Matias Creimerman

I’m a specialist in design, development and management of software solutions with 20 years of experience. Microsoft Certificated Professional (MCP). Expert in dot net and Microsoft technologies. Experience and skills in designing solutions in a wide range of commercial, industrial and production areas. Design of architectures, software applications and processes. Skills in leadership and team management. Tech trainer. Technology researcher. Self-taught and dedicated to continuous learning. Skills in estimation, quotation, projects proposals and solutions design. Entrepreneurial spirit. Strong Tech profile but also customer oriented. I perform roles as fullstack dev, tech consultant, technical referent, development leader, team leader, architect, cross leader, tech manager, tech director, trainer, ramp-up & follow-up teams, software factory manager, DevOps and release manager. Regular chess player and musician.

Categorías Trainings,TutorialsEtiquetas , , , , Deja un comentario

Responder

Introduce tus datos o haz clic en un icono para iniciar sesión:

Logo de WordPress.com

Estás comentando usando tu cuenta de WordPress.com. Cerrar sesión /  Cambiar )

Google photo

Estás comentando usando tu cuenta de Google. Cerrar sesión /  Cambiar )

Imagen de Twitter

Estás comentando usando tu cuenta de Twitter. Cerrar sesión /  Cambiar )

Foto de Facebook

Estás comentando usando tu cuenta de Facebook. Cerrar sesión /  Cambiar )

Conectando a %s