Dataset Parser Error

Dataset Parser Error

Postby zzz » Mon 11 Jun 2007 00:40

I have been using the professional version of the driver for a couple days now without any problems. However I just recently started using datasets in my project and I ran into this problem.

Everything works great on my development server however when I try and upload it to my ISP server I get this error: Am I forgetting to copy a DLL over or something alongs those lines?

Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

Parser Error Message: Failed to generate code. Exception of type 'System.Data.Design.InternalException' was thrown.

Source Error:
Line 1:
Line 2:
Line 3:

Source File: /App_Code/dsUsers.xsd Line: 1

-------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.210
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby Alexey » Mon 11 Jun 2007 08:02

Of course, you need to upload our run-time asseblies as well.
When exactly do you get the error?
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby zzz » Mon 11 Jun 2007 13:20

The errors takes place after I add a dataset to the project. Everything works fine on my home PC, but when I update to my web host I get the error listed above.

1. I create a project with a blank aspx page.
2. I create a dataset using the mysql provider
3. Run it on my home PC and everything works.
4. Copy it to my web hosting site
5. Try and access the blank page and I get the error message listed above.

Just to check I was able to create a dataset with the MS SQL provider without the error message coming up.

I have tried copying up different combinations of the dll files without luck.

This is what is currently in my bin folder:
CoreLab.Data.dll
CoreLab.MySql.dll
CoreLab.MySql.Web.dll
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby Alexey » Mon 11 Jun 2007 16:31

3. Run it on my home PC and everything works.
4. Copy it to my web hosting site

Copy what? Run what? If I got you right, you copy *.xsd file to another PC, add it there to a blank project, run the project and get the error - yes?
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby zzz » Mon 11 Jun 2007 17:10

The project is in asp.net so I copy all the files from the project's IIS folder and the included sub folders. The dataset files are in the apps_code folder.

Then I try and access the aspx file through the web browser (default.aspx) and I get the error.

If I remove the dataset files from the project default.aspx file will open. If any dataset is present using the core mysql provider the error message appears when I try and access the aspx file through the web browser.

So what I am doing is creating an IIS web project in visual studio 2005 with the default settings (default web.config, blank default.aspx) then creating a dataset using the core labs mysql provider. I do this on my home PC and it runs great.

Then I copy the project folder to my web host. Copy the DLL files (CoreLab.Data.dll, CoreLab.MySql.dll, CoreLab.MySql.Web.dll) to bin. Then try and access the default.aspx file through internet explorer (this step on a project that I have not added the dataset to) and I get the error message.
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby zzz » Tue 12 Jun 2007 00:21

Update:
I uninstall the provider and the developer tools on my home computer.
The same error as in the first message now comes up.

I put these 4 files in the bin directory.
CoreLab.Data.dll
CoreLab.MySql.dll
CoreLab.MySql.Web.dll
App_Licenses.dll

The error still comes up.

I reinstall just the provider and not developer tools. The error goes away. However I unable to install the exe on my web host so this is not a solution for me.
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby Alexey » Wed 13 Jun 2007 05:52

How do you create the dataset?
Please send me your web site project.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby zzz » Wed 13 Jun 2007 13:44

1. Create a web site using visual studio 2005
web.config
default.aspx (this is a blank page without any controls)
Are created automatically

2. Right click on the project select add dataset. Visual studio says that the dataset should be in Apps_code and asks if it can move it there. I click yes.

3. Choose the MySQL Database (MySQLDirect .NET) database provider and type in the information.

4. Click test connection (success)

5. The table adapter comes up. Select all the fields from the users tables. Click ok.

6. Copy
CoreLab.Data.dll
CoreLab.MySql.dll
CoreLab.MySql.Web.dll

To the bin folder.

7. Set Default.aspx as the default start page and click play in visual studio. The blank page is displayed. In my real project I actually use the dataset tableadapter functions to query the database and it works.

8. Copy everything including the bin files to my web host.

9 Go to internet explorer and try and access default.aspx.

10 I receive the same error as in the first post.

If I delete the dataset from my host everything works. So there is something different involving my computer and the host computer in regards to the dataset file.

I will email you a copy of the project with a working connection to the database.
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby Alexey » Thu 14 Jun 2007 15:58

Unfortunately, I can't reproduce this problem on a clean Windows XP. Have you tried to do the same on another PC? What is your operating system?
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby zzz » Mon 18 Jun 2007 22:54

I've tried this on my web hosting server and my personal PC. Could you list what steps have to be taken to deploy the driver for a ASP.net web app where the core labs client has not been installed using the exe? What components/dlls have to be present on the server etc.
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby Alexey » Tue 19 Jun 2007 06:14

To deploy applications written with MySQLDirect .NET you should register run-time assemblies CoreLab.MySql.dll and CoreLab.Data.dll at Global Assembly Cache (GAC) for appropriate framework or place them in the folder of your application (Bin folder for web projects).
When deploying ASP.NET website applications it is also necessary to have CoreLab.MySql.Web.dll and App_Licenses.dll assemblies available.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby zzz » Tue 19 Jun 2007 12:52

I followed these instructions step by step. I cannot register items to the GAC for my web host so I go the dll route and it does not work. Are you able to get this working on a clean machine with just those 4 dll files with a dataset added to the project using visual studio rather then using the dataset wizard that comes with the core labs tools?

I just tried this on a friends computer and it didn't work there either if I didn't install the core labs mysql driver and developer tools. If I install the driver the program works on his computer.

This leads me to believe that the exe file mysqlnet400pro2.exe is doing more then just registering these items in the gac. This is three seperate computers that I am having this problem on.
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby Alexey » Wed 20 Jun 2007 08:40

I am able to run my project without any assemblies at all, because Default.aspx page doesn't refer to either of them.
Please send me your project. I'll try to run it on a clean Windows XP.
Use e-mail address provided in the Readme file.
Alexey
 
Posts: 2756
Joined: Mon 13 Mar 2006 07:43

Postby zzz » Wed 20 Jun 2007 12:10

When I create the dataset in visual studio 2005 it has me put the dataset in the apps_code folder. The files in the apps_code folder are automatically compiled at runtime. So when I try and access the default.aspx via internet explorer it crashes the program while trying to compile the dataset.

I just sent an email with the project in an attached file zip file.
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Postby zzz » Wed 20 Jun 2007 23:16

Good news. I updated my account to a dedicated server. I was able to install the exe and everything works now. So I should be all set!

I was never able to figure out to do this with just dll files.

Thanks for your help.
zzz
 
Posts: 9
Joined: Mon 11 Jun 2007 00:36

Next

Return to dotConnect for MySQL