[WebMethod] public List<employeeinformation> GetAllInfor() { DataClasses1DataContext dbcontext = new DataClasses1DataContext(); var EMPLOYEEEntity = (from p in dbcontext.EMPLOYEEInformations select p); return EMPLOYEEEntity.ToList(); }
using System; using System.Collections.Generic; class Program { static void Main() { List<string> dogs = new List<string>(); // Create new list of strings dogs.Add("Aigi"); // Add string 1 dogs.Add("Spitz"); // 2 dogs.Add("Mastiff"); // 3 dogs.Add("Finnish Spitz"); // 4 dogs.Add("Briard"); // 5 string dogCsv = string.Join(",", dogs.ToArray()); Console.WriteLine(dogCsv); } }
List<string> names = new List<string>() { "John", "Anna", "Monica" }; var result = String.Join(", ", names.ToArray());
var names = new List<string>() { "John", "Anna", "Monica" }; var joinedNames = names.Aggregate((a, b) => a + ", " + b);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)