Datatables .NET
Datatables .NET
Paulus
Posts: 69Questions: 17Answers: 5
Just purchased and downloaded this library, but it will not compile in VS 2013. What is going on here?
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
That's odd - I use VS2013 myself!
What errors are being shown by the compiler?
Thanks,
Allan
36 errors in all and all from the Query classes of the various database types.
It might be due to the unprofessional naming system resulting in stuff like
public class Query : DataTables.Query
I have just tried it and it compiles under VS 2015 without any problem.
Could you show me the errors please? There are one or two classes which don't match the conventions for naming style on the private properties, but that wouldn't generate an error. A warning at worst would be shown, although that is more of a linting message rather than a compiler one.
Regards,
Allan
Here is the list, I only removed the drive information (with ...)
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(16,54,16,56): error CS1002: ; expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(16,60,16,61): error CS1031: Type expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(16,60,16,61): error CS1519: Invalid token '[' in class, struct, or interface member declaration
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(16,61,16,62): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(16,63,16,64): error CS1031: Type expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(16,63,16,64): error CS1519: Invalid token '{' in class, struct, or interface member declaration
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(23,16,23,21): error CS1518: Expected class, delegate, enum, interface, or struct
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(32,28,32,32): error CS1518: Expected class, delegate, enum, interface, or struct
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(51,43,51,44): error CS1518: Expected class, delegate, enum, interface, or struct
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(65,13,65,18): error CS0116: A namespace cannot directly contain members such as fields or methods
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Mysql\Query.cs(68,9,68,10): error CS1022: Type or namespace definition, or end-of-file expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Oracle\Query.cs(43,44,43,46): error CS1002: ; expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Oracle\Query.cs(45,46,45,48): error CS1002: ; expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(17,55,17,57): error CS1002: ; expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(17,61,17,62): error CS1031: Type expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(17,61,17,62): error CS1519: Invalid token '[' in class, struct, or interface member declaration
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(17,62,17,63): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(17,64,17,65): error CS1031: Type expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(17,64,17,65): error CS1519: Invalid token '{' in class, struct, or interface member declaration
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(24,16,24,21): error CS1518: Expected class, delegate, enum, interface, or struct
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(35,28,35,34): error CS1518: Expected class, delegate, enum, interface, or struct
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(65,28,65,32): error CS1518: Expected class, delegate, enum, interface, or struct
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(100,38,100,39): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(113,34,113,47): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(114,66,114,77): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(114,91,114,104): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(115,66,115,77): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(117,54,117,67): error CS1001: Identifier expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(120,17,120,18): error CS1022: Type or namespace definition, or end-of-file expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(121,13,121,14): error CS1022: Type or namespace definition, or end-of-file expected
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(123,13,123,16): error CS0116: A namespace cannot directly contain members such as fields or methods
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(130,43,130,44): error CS1518: Expected class, delegate, enum, interface, or struct
1>...\Editor-NET-1.6.0\DataTables\DataBaseUtil\Sqlserver\Query.cs(142,13,142,14): error CS1022: Type or namespace definition, or end-of-file expected
1>...\Editor-NET-1.6.0\DataTables\Query.cs(79,43,79,45): error CS1002: ; expected
1>...\Editor-NET-1.6.0\DataTables\Query.cs(81,54,81,56): error CS1002: ; expected
1>...\Editor-NET-1.6.0\DataTables\Query.cs(83,45,83,47): error CS1002: ; expected
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Thank you. It looks like a C# compiler version issue. The code will compile with C# 6, but it is not valid C# 5 (VS 2013 shipped with just C# 5, so it won't actually compile out of the box).
You can install an updated C# compiler in VS 2013 from Nuget which is appear that I've done (and forgotten about!).
Allan
You are using C# 6 syntax? So, one will have to update the Compiler for each generated output for it to work. Why not add that package to the generator output, if it requires it to compile.
I see no need for this and do not plan to use the library itself. Just trying to get to know who this works by testing the output.
Yes.
If your default compiler is set to be C# 5 or older, then yes, I'm afraid so.
It isn't needed if you use VS2015, but the C# 6 compiler wasn't included in VS2013 (not available then), so it would be in VS2013. I'll take a look and see if I can make a change to allow for that.
Perhaps it was a mistake to jump to C# 6 already! It does add some nice features though .
Allan