Yes, I try it, but fail.
My code is like this :
Dim SqlConnection1 As New System.Data.SqlClient.SqlConnection
Dim SqlSelectCommand1 As New System.Data.SqlClient.SqlCommand
Dim SqlDataAdapter1 As New System.Data.SqlClient.SqlDataAdapter
Dim SqlDataSet1 As New System.Data.DataSet
SqlConnection1.ConnectionString = "data source=" &
openFileDialog1.FileName() & ";Password=abc;persist security
info=True;packet size=4096"
SqlDataAdapter1.SelectCommand = SqlSelectCommand1
SqlSelectCommand1.CommandText = "SELECT * from tblBook"
SqlSelectCommand1.Connection = SqlConnection1
SqlConnection1.Open()
SqlDataAdapter1.Fill(SqlDataSet1)
SqlDataAdapter1.TableMappings.Add("tblBook", "strBookFullThai")
SqlDataSet1.Tables("tblBook").Columns("strBookFullThai")
"Jon Skeet [C# MVP]" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Microsoft <(E-Mail Removed)> wrote:
> > I have one SQL CE database (two tables : one has 100 records, another
has
> > 30,000+ records) on my PocketPC.
> > And I try a lot of ways to connect and query it.
> >
> > What components I have to use?
> > What commands I have to use?
> > How can I query it?
>
> Use SqlCeDataAdapter, SqlCeConnection, SqlCeCommand etc. The
> documentation for each of them should provide you with enough
> information to go from there, if you've got other ADO.NET experience -
> if not, look through a "normal" (desktop) ADO.NET tutorial first.
>
> --
> Jon Skeet - <(E-Mail Removed)>
> http://www.pobox.com/~skeet
> If replying to the group, please do not mail me too