C# How can I convert an input number into a correct decimal output? (newbie) : I am a total newbie with almost zero coding knowledge.  Thanks to all of you who will bother answering me.

I have tried to look for that question in Stackoverflow before I ask, but I have not found anything (may be due my lack of experience).

Now, my question:  How can I convert an input number into a correct decimal output?

I have tried with the code below (following a free course of the Microsoft Virtual Academy) but it only works when I remove my variable.

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    
    namespace ConsoleApp1
    {
        class Program
        {
            static void Main(string[] args)
            {
                //string myString = "My \"so-called\" life";
                //string myString = "What if I need a\nnew line?";
                //string myString = "Go to your c:\\drive";
                //string myString = @"Go to your c:\drive";
                //string myString = String.Format("{0} = {1}", "First", "Second");
                //string myString = String.Format("{0:C}", 123.45);
                Console.Write("Insert a number: ");
                var data1 = Console.ReadLine();
                string myString = String.Format("{0:N}", data1);
    
                Console.WriteLine(myString);
                Console.ReadLine();
            }
        }
    }

Thanks again,
Alex
