Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Some problems encountered in copying code LA from Linqpad
#2
LA uses standard C#. It can be either class with Main, or top-level statements without Main.

In this case either:
1. Put both functions into a class.

class Program {
put code here
}

2. Or convert the code to valid top-level statements: move Main code out of Main (and delete Main), and delete the 'public' keyword (then the function will be a local function).

----------

About 'Add missing using directives': LA finds classes with same name in multiple namespaces, and cannot know which are correct. Either delete wrong usings, or click No and then add good usings.


Messages In This Thread
RE: Some problems encountered in copying code LA from Linqpad - by Gintaras - 10-13-2022, 10:36 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)