Hi all
Using VS2005 c#, FB 2.1 embeded, Fb.Net 2.1.0 provider.
I try to port some off my old application from Delphi and dbf files to c#
and fbembeded.
I try to keep existing folders as they are and I have added new folder for
fbembeded files.
When I run application I get error because fbembed.dll is not found in app
folder. I have tried to specify the client library as :
string apppath =
System.IO.Path.GetDirectoryName(Application.ExecutablePath.ToString());
FbConnectionStringBuilder fbcs = new
FbConnectionStringBuilder();
fbcs.ServerType = FbServerType.Embedded;
fbcs.Database = apppath + @"\Data\mydb.fdb";
fbcs.Charset = "NONE";
fbcs.ClientLibrary = apppath + @"\fb\fbembed.dll"; <- if I
comment this and copy all needed files to app folder, error disapear
using (FbConnection fb = new FbConnection(fbcs.ToString()))
{
try
{
fb.Open();
DataTable dt = new DataTable();
FbCommand fbc = new FbCommand("Select * from
SYS_DATABASES", fb);
FbDataAdapter fbda = new FbDataAdapter(fbc);
fbda.Fill(dt);
dataGridView1.DataSource = dt;
}
catch (FbException fbex)
{
MessageBox.Show(fbex.Message);
}
}
But I get this error:
Method not found : 'Void
FirebirdSql.Data.FirebirdClient.ConnectionStringBuilder.set_ClientLibrary(Sy
stem.String)'
If I copy all needed files to app folder and I comment line :
fbcs.ClientLibrary = apppath + @"\fb\fbembed.dll"; the application work ok!
What I'm doing wrong?
Thanks,
Paul
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Firebird-net-provider mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/firebird-net-provider