Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

C# 

C# problem in VSCode.

I run a simple Hello World program and I get this.

OUTPUT:

[Running] scriptcs "/Users/macbook/Desktop/C#/test.cs"
Unexpected named argument: Users/macbook/Desktop/C#/test.cs

[Done] exited with code=1 in 2.482 seconds
Please post your code or there’s no way to tell what went wrong
[Image: Syr3DlV.png]
u probably forgot the Console.ReadLine(); after Console.WriteLine("");
Try this and see if it fails too
Code
using System;

namespace HelloWorld {
  public static class Program {
    public static void Main(string[] argv) {
        Console.WriteLine("Hello world");
    }
  }
}
[Image: Syr3DlV.png]
put
Code
Console.ReadKey(true);
after
Code
Console.WriteLine("Hello world");


Possibly Related Threads...
Thread / Author Replies Views Last Post
[Python] by BastilleJun 9, 2020 12:42 PM 4 179 Jun 9, 2020 12:42 PM
Last Post: Bastille
[C] by dsp250May 11, 2020 04:41 AM 6 161 May 11, 2020 04:41 AM
Last Post: Shisho
[Python] by ⁣Null⁣Mar 6, 2017 03:18 AM 7 197 Mar 6, 2017 03:18 AM
Last Post: SIM-1866423