- Home /
The question is answered, right answer was accepted
TypeLoadException with libraries in C#
Hello, I've searched the internet for the past 2 days to find out myself, but I didn't find anything useful or up to date for my problem, so here it is:
I am currently working on a 2D MMORPG nothing really too important, but the thing is, I want to connect to the database, (what actually should work) But I happen to have this strange error, (I can actually start the game tho).
Here's the beginning of the DB.cs (where the database stuff is)
Error:
TypeLoadException: Could not load type 'System.Data.SqlClient.SqlConnection' from assembly 'System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.
using UnityEngine;
using System.Collections;
using System.Data;
using MySql.Data.MySqlClient;
If you need any other codelines tell me.
Answer by Graham-Dunnett · Jul 12, 2013 at 09:10 PM
See:
http://docs.unity3d.com/Documentation/ScriptReference/MonoCompatibility.html
The runtime Mono support does not include System.Data.
Well I tried setting the compability Level to .NET 2.0 already and tried to import the missing libraries.. but that wouldn't solve the problem, does that mean it's >impossible< to use those dll?
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Access a MySQL database via C# ? 2 Answers
How to pass SQL vars? 1 Answer
Distribute terrain in zones 3 Answers
System.Globalization.CCEastAsianLunisolarCalendar.GetMonth (DateTime date) 2 Answers