其實是輸出結果了﹐只是dos窗閃的過快﹐你沒看到了

解决方案 »

  1.   

    using System;
    class welcome
    {
      public static void Main()
      {
        Console.WriteLine("Welcome to you!");
        Console.ReadLine();
      }
    }
      

  2.   

    如何控制dos窗口,能够看到信息呢?
      

  3.   

    using System;
    class welcome
    {
      public static void Main()
      {
        Console.WriteLine("Welcome to you!");
        Console.ReadLine();
      }
    }
    Console.ReadLine()的作用是让程序读1行文件
    因为程序现在无文本可读,会运行到Console.WriteLine("Welcome to you!");
    停下来。你既可以看到结果。
      

  4.   

    如何控制dos窗口,能够看到信息呢?
    -------------------------------------------
    csc命令只是编译生成.exe文件.
    1、先执行命令: csc welcome.cs,此时生成了一个welcome.exe文件
    2、再运行: welcome.exe如下:C:\WINNT\Microsoft.NET\Framework\v1.0.3705>csc welcome.c
    Microsoft (R) Visual C# .NET Compiler version 7.00.9466
    for Microsoft (R) .NET Framework version 1.0.3705
    版权所有 (C) Microsoft Corporation 2001。保留所有权利。
    C:\WINNT\Microsoft.NET\Framework\v1.0.3705>welcome.exe
    Welcome to you!
      

  5.   

    看来楼主是初学者。
    以上各位所言均可。
    Console.ReadLine();等待输入一行
    Console.Read();等待输入任意字符
    打开输出窗口看结果
    命令行cmd下编译并运行(此时应指定路径或者设定PATH)
      

  6.   

    利用SDK太
    想看到输出结果,就在输出之后加上输入语句等待输入即可