Subject RE: [firebird-support] Using Firebird With C#
Author Si Carter
> -----Original Message-----
> Hi guys, i just started using C# and Visual Studio, i use
> firebird with php and its very simple to work with, but i m
> having some trouble to make it work with C#.
>
> I tried this:
>
> private void Form1_Load(object sender, EventArgs e) {
> string connectionString = "Database=
> 192.168.15.101:/home/trab/SiadPHP/testes/siad.gdb
> ;User=SYSDBA;Password=masterkey;Dialect=3;";
> FbConnection cnn = new FbConnection(connectionString);
> FbDataAdapter da = new FbDataAdapter("SELECT *
> FROM RDB$RELATIONS", cnn);
> DataTable dt = new DataTable("RELATIONS");
> da.Fill(dt);
> da.Dispose();
>
> dataGrid1.DataSource = dt;
> }
>
> But it gives me this error:
>
> "Unable to complete network request to host 192.168.15.101"

Visit (http://www.fbtalk.net/viewtopic.php?id=257) for a base class for use
with FB.net/C#.

FYI, this is one of my connection strings

User=DNFDB_USER;Password=h6tr3sc7;Database=dnfdb;DataSource=127.0.0.1;Dialec
t=3;Pooling=false;Connection Lifetime=600;Packet Size=8192

You will notice that the Datasource (server) is an entry by its self.

Hih

Si Carter
http://www.fbtalk.net/ - Web Based Firebird Forum
http://sourceforge.net/projects/fbutils - FBUtils
http://sourceforge.net/projects/dnfbb - Web based, Firebird Powered Forum