Tyring to load System.data

Tyring to load System.data

Postby Ultima » 16 Dec 2011, 14:23

I am trying to make a command but it uses System.Data (needs database access)

When i try to compile it, it says its missing System.data.
Is their a way to load it?

I noticed in Visual studio 2010, that it doesnt have it either but when i change the buildtype to Compile, it does.
How to change/add this in mcdzienny? :?

Edit:

Am trying to use
Code: Select all
Database.fillData();


Ups, forgot to press the subforum.. :mrgreen:
User avatar
Ultima
 
Posts: 953
Joined: 19 Aug 2011, 23:45

Re: Tyring to load System.data

Postby dzienny » 16 Dec 2011, 14:26

You have to add references in VS to MySQL.Data.dll that is located in the game directory.
User avatar
dzienny
Administrator
 
Posts: 1181
Joined: 23 Jan 2011, 14:27

Re: Tyring to load System.data

Postby Ultima » 16 Dec 2011, 14:28

dzienny wrote:You have to add references in VS to MySQL.Data.dll that is located in the game directory.


And how do i do that? :mrgreen:
Am still learning on the go..
User avatar
Ultima
 
Posts: 953
Joined: 19 Aug 2011, 23:45

Re: Tyring to load System.data

Postby dzienny » 16 Dec 2011, 14:32

Project > Add reference... > Browse
and then add both MCDzienny_.dll and MySql.Data.dll

Also add System.Data, again

Project > Add reference... > .NET
and choose System.Data
User avatar
dzienny
Administrator
 
Posts: 1181
Joined: 23 Jan 2011, 14:27

Re: Tyring to load System.data

Postby Ultima » 16 Dec 2011, 14:48

dzienny wrote:Project > Add reference... > Browse
and then add both MCDzienny_.dll and MySql.Data.dll

Also add System.Data, again

Project > Add reference... > .NET
and choose System.Data


Thanks, i will try that.
It seems i broke something in my visual studio and need to reinstall it.
User avatar
Ultima
 
Posts: 953
Joined: 19 Aug 2011, 23:45

Re: Tyring to load System.data

Postby dzienny » 16 Dec 2011, 15:09

Ultima wrote:
dzienny wrote:Project > Add reference... > Browse
and then add both MCDzienny_.dll and MySql.Data.dll

Also add System.Data, again

Project > Add reference... > .NET
and choose System.Data


Thanks, i will try that.
It seems i broke something in my visual studio and need to reinstall it.


It's highly unlikely. Just make sure that you create a new project that is Class Library, this way it will compile to *.dll file.
Also add "using MCDzienny;" in the header of the code. And don't forget about references to MCDzienny_.dll library.
User avatar
dzienny
Administrator
 
Posts: 1181
Joined: 23 Jan 2011, 14:27

Re: Tyring to load System.data

Postby Ultima » 16 Dec 2011, 15:14

dzienny wrote:It's highly unlikely. Just make sure that you create a new project that is Class Library, this way it will compile to *.dll file.
Also add "using MCDzienny;" in the header of the code.


No really, i broke it :mrgreen:
Giving a error when i try to start visual studio.
User avatar
Ultima
 
Posts: 953
Joined: 19 Aug 2011, 23:45


Return to Help in Coding

Who is online

Users browsing this forum: No registered users and 2 guests

cron