No, You can not mix vb and c# within the same project,but you can use them in the same solution. An assembly/project (each project compiles to 1 assembly usually) has to be one language. However, you can use multiple assemblies, and each can be coded in a different language because they are all compiled to MSIL.
You can add vb.net files to a c#.net project. Compilation also works. It compiles fine and didn’t complain because a C# project will only actually compile the .cs files. It will ignore the other ones, therefore you will not receive errors.
Note: If you add a .vb file to a C# project, select the file in the Solution Explorer panel and then look at the Properties panel, you’ll notice that the Build Action is ‘Content’, not ‘Compile’. It is treated as a simple text file and doesn’t even get embedded in the compiled assembly as a binary resource.
var totalRows = myDatatable.Rows.Count;
var halfway = totalRows/2;
var firstHalf = myDatatable.AsEnumerable().Take(halfway).CopyToDataTable();
var secondHalf = myDatatable.AsEnumerable().Skip(halfway).Take(totalRows – halfway).CopyToDataTable();
// the config file contains the specific key
but if you only want to check the value
var specificValue =ConfigurationManager.AppSettings["specificKey"];
// Use the value