Error Message

Smee

Well-Known Member
Licensed User
Longtime User
i have an error message when i am compiling
my program. I have installed Net compact 2.0. The error is
Error Compiling program.
Error message: error CS0012:
the type 'system.data.common.dbconnection' is defined in an assembly that is not referenced.
You must add a reference to assembly 'system.data, Version=2.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089'

The program compiles OK for Windows.exe but not for the device

it only happens if i select "optimised compiling". Is there something else i need to do?


Thanks
 
Last edited:

Smee

Well-Known Member
Licensed User
Longtime User
Hi Agraham,

i know the problem is related to the sql library i am using

on the device i have the System.Data.SQLite.Device.dll
on the desktop side i have the SQLDesktop.dll

the compile error i am getting now is

the type or namespace name 'B4PSQL' could not be found

:sign0085:
 

Smee

Well-Known Member
Licensed User
Longtime User
Thanks for the reply,

Yes i had just done that and it compiled. I got a message to add the System.Data.SQLite.Device.dll and the sqlite.interop.060.dll to the setup files which i did.

i installed the program to the device and i got errors regarding sql operations when i ran the software
"an error message cannot be displayed because an optional resource assembly containing it cannot be found
 

Smee

Well-Known Member
Licensed User
Longtime User
Hi,

I have done that, uninstalled and then reinstalled the app but it has not made any difference. i checked the device and i have .net cf 2.0 enu-string..... in the program settings.

What can i try next?
:sign0085::sign0085:
 

Smee

Well-Known Member
Licensed User
Longtime User
I am getting the same error message on the device. i.e it appears the database files are not being loaded. the program will fire up when i say continue but there are no db files
:BangHead:
 

Smee

Well-Known Member
Licensed User
Longtime User
Sorry but its past midnight annd i am getting tired.
after clicking i get an error saying
An error occured on sub_main_createcustomertable.

An error message cannot be displayed because an optional resource assembly containing it cannot be found
Continue?
Yes NO

if i press y i get further similar messages until the form loads. if i press N then the form loasds straight away but no database info is shown.

i have checked the folder and the database has been installed with the executable

I am using an MC5590, yes english device

tks for your help

Any further ideas Andrew?

thanks
 
Last edited:

Smee

Well-Known Member
Licensed User
Longtime User
yes i checked 3 times that the correct cab was used. i downloaded the other vewrsion and checked it to make sure
 

Smee

Well-Known Member
Licensed User
Longtime User
Hi,
I am attatching an image which shows the files i am compiling these are correct are they not?
 

Attachments

  • Untitled.jpg
    Untitled.jpg
    12.1 KB · Views: 176

agraham

Expert
Licensed User
Longtime User
The files look fine. If you still don't have proper error messages I am afraid that I have no further ideas. When I needed to load that cab onto my WM6 device it just worked. You might be able to get a clue as to what the error might be by trapping it with Errorlabel and using either my Exceptions library or the Door library to look at B4PObject(6). It is the type name of the InnerException that is probably the one to look at.
 

Smee

Well-Known Member
Licensed User
Longtime User
Hi again,

I have just read a reply to an earlier question i had posted. Basically Geoff said that the setup.exe is used to install to a pc but the cab files are used on the device. Maybe this is my problem? I am running the setup.exe which i had assumed was putting the correct files on the device. is this not the way to do it? maybe the device does not have all the correct files?

thanks for your help

Joe
 

Smee

Well-Known Member
Licensed User
Longtime User
Where does this setup.exe come from? Why haven't you just copied the files to a folder on the device?

it is created by setupbuilder along with 2 cab files ARM.cab and ARMV4.cab.

should i just copy the cab file or files? if one is it the V4 or the other one

thanks

Ok i copied the cab files across and installed from them.

i still get the error

"An error occurred on sub_main_createcustomertable."


this is the code of that sub routine

Sub CreateCustomerTable
command.CommandText="Drop Table If Exists Customers"
Command.ExecuteNonQuery
CustTable.LoadCSV ("muCustomers.csv", ",", True, True)
SQLConn.CreateSQLTable("CustTable","Customers")

End Sub


OH BUGGER!!!!!!!!

I think i see it. I have not copied the bloody csv file across.
i will copy that and advise shortly
 
Last edited:

Smee

Well-Known Member
Licensed User
Longtime User
Andrew,

Thank you very much for your help and patience.

The missing file was indeed the culprit. I feel such an idiot for wasting my time and more importantly, yours

thanks again

Joe
:sign0060::sign0060::sign0060::sign0060:
 
Top