I have an MSDE database on a server "RWPSRV1", and an Access project on several clients to track loaner cars. I am attempting to create a PDA based return form using Visual Studio.Net. The server will be accessed via a wireless network (not web based). I am using the built-in Pocket PC emulator that comes with VS.net. for the test -- not an actual PPC. I have a Symbol PPT8800 that I can use if necessary

The problem I am having is connecting to the MSDE SQL server. Below is the code to a simple form I created to test connectivity with several Dim statements I tried. I included all the code but the coonection attempts start near the end at "Try". Mostly, the trapped messages state that the path is wrong or the server does not exist. The first Dim statement works fine (connects) in a windows application form in VS.net -- but not the Smart Application

Can someone point out the error(s) of my ways

Is it possible that the emulator does not "connect" but the Symbol (or other PPPC) would

Imports System.Data.SqlClien
Imports System.Data.SqlServerC

Public Class Form
Inherits System.Windows.Forms.For
Friend WithEvents MainMenu1 As System.Windows.Forms.MainMen

#Region " Windows Form Designer generated code

Public Sub New(
MyBase.New(

'This call is required by the Windows Form Designer
InitializeComponent(

'Add any initialization after the InitializeComponent() cal

End Su

'Form overrides dispose to clean up the component list
Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean
MyBase.Dispose(disposing
End Su

'NOTE: The following procedure is required by the Windows Form Designe
'It can be modified using the Windows Form Designer.
'Do not modify it using the code editor
Private Sub InitializeComponent(
Me.MainMenu1 = New System.Windows.Forms.MainMen

'Form

Me.Menu = Me.MainMenu
Me.Text = "Form1

End Su

#End Regio

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Loa

Try
Dim conn As New SqlConnection("server=RWPSRV1;uid=sa;database=CV4a01SQL"

'Dim conn As New SqlConnection("server=RWPSRV1;uid=sa;password=;database=CV4a01SQL"

'Dim conn As SqlCeConnection
'Dim DataPath As Strin
'DataPath = "RWPSRV1\CV4a01SQL
'conn = New SqlCeConnection("Data Source=" & DataPath

'Dim conn As New SqlCeConnection
'conn.ConnectionString = "Persist Security Info=False; Data Source = \\RWPSRV1\d$\MSDEData\CV4a01SQL" +
'"Password =

'Dim conn As New SqlCeConnectio
'conn.ConnectionString = "Data Source = RWPSRV1\d$\MSDEData\CV4a01SQL.mdf

'Dim conn As SqlServerCe.SqlCeConnectio
'conn.ConnectionString = "server=RWPSRV1;uid=sa;database=ADP_Records2

conn.Open(
If (conn.State = ConnectionState.Open) The
MessageBox.Show("Connection opened successfully"
End I
conn.Close(

Catch ex As SqlException 'SqlCeException - use this when testing CE string
MessageBox.Show(ex.Message
End Tr

End Su

End Clas

Thanks for any help you could provide

Re: Connecting Pocket PC to MSDE Sql by KS

KS
Fri May 28 10:22:40 CDT 2004

That is correct .. there is no way to connect to SQLServer from PocketPC
directly. There are a couple 3rd party tools that people have written that
allows you to do this through ADO. Basically all they do is open a socket
connection to an application that is running on your server that passes the
data back and forth across the socket.

KS


"Randy" <anonymous@discussions.microsoft.com> wrote in message
news:3E52277B-5A9D-4D43-99A2-E6662E470F21@microsoft.com...
> I have an MSDE database on a server "RWPSRV1", and an Access project on
several clients to track loaner cars. I am attempting to create a PDA based
return form using Visual Studio.Net. The server will be accessed via a
wireless network (not web based). I am using the built-in Pocket PC emulator
that comes with VS.net. for the test -- not an actual PPC. I have a Symbol
PPT8800 that I can use if necessary.
>
> The problem I am having is connecting to the MSDE SQL server. Below is
the code to a simple form I created to test connectivity with several Dim
statements I tried. I included all the code but the coonection attempts
start near the end at "Try". Mostly, the trapped messages state that the
path is wrong or the server does not exist. The first Dim statement works
fine (connects) in a windows application form in VS.net -- but not the Smart
Application.
>
> Can someone point out the error(s) of my ways?
>
> Is it possible that the emulator does not "connect" but the Symbol (or
other PPPC) would?
>
>
> Imports System.Data.SqlClient
> Imports System.Data.SqlServerCe
>
> Public Class Form1
> Inherits System.Windows.Forms.Form
> Friend WithEvents MainMenu1 As System.Windows.Forms.MainMenu
>
> #Region " Windows Form Designer generated code "
>
> Public Sub New()
> MyBase.New()
>
> 'This call is required by the Windows Form Designer.
> InitializeComponent()
>
> 'Add any initialization after the InitializeComponent() call
>
> End Sub
>
> 'Form overrides dispose to clean up the component list.
> Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean)
> MyBase.Dispose(disposing)
> End Sub
>
> 'NOTE: The following procedure is required by the Windows Form
Designer
> 'It can be modified using the Windows Form Designer.
> 'Do not modify it using the code editor.
> Private Sub InitializeComponent()
> Me.MainMenu1 = New System.Windows.Forms.MainMenu
> '
> 'Form1
> '
> Me.Menu = Me.MainMenu1
> Me.Text = "Form1"
>
> End Sub
>
> #End Region
>
> Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
>
> Try
> Dim conn As New
SqlConnection("server=RWPSRV1;uid=sa;database=CV4a01SQL")
>
> 'Dim conn As New
SqlConnection("server=RWPSRV1;uid=sa;password=;database=CV4a01SQL")
>
> 'Dim conn As SqlCeConnection
> 'Dim DataPath As String
> 'DataPath = "RWPSRV1\CV4a01SQL"
> 'conn = New SqlCeConnection("Data Source=" & DataPath)
>
> 'Dim conn As New SqlCeConnection
> 'conn.ConnectionString = "Persist Security Info=False; Data
Source = \\RWPSRV1\d$\MSDEData\CV4a01SQL" + _
> '"Password ="
>
> 'Dim conn As New SqlCeConnection
> 'conn.ConnectionString = "Data Source =
RWPSRV1\d$\MSDEData\CV4a01SQL.mdf"
>
> 'Dim conn As SqlServerCe.SqlCeConnection
> 'conn.ConnectionString =
"server=RWPSRV1;uid=sa;database=ADP_Records2"
>
> conn.Open()
> If (conn.State = ConnectionState.Open) Then
> MessageBox.Show("Connection opened successfully")
> End If
> conn.Close()
>
> Catch ex As SqlException 'SqlCeException - use this when
testing CE strings
> MessageBox.Show(ex.Message)
> End Try
>
> End Sub
>
> End Class
>
>
> Thanks for any help you could provide.
>
>
>
>
>



Re: Connecting Pocket PC to MSDE Sql by kiln

kiln
Tue Jun 01 00:00:25 CDT 2004

He can't connect from PocketPC to SQL Server, but he can connect to SQL
Server CE and that can link to SQL Server proper...at least that is my
understanding, and I don't know if it's of any help to the original
poster.

In article <#X2keeMREHA.556@tk2msftngp13.phx.gbl>, ks@blah.com says...
> That is correct .. there is no way to connect to SQLServer from PocketPC
> directly. There are a couple 3rd party tools that people have written that
> allows you to do this through ADO. Basically all they do is open a socket
> connection to an application that is running on your server that passes the
> data back and forth across the socket.
>
> KS
>
>
> "Randy" <anonymous@discussions.microsoft.com> wrote in message
> news:3E52277B-5A9D-4D43-99A2-E6662E470F21@microsoft.com...
> > I have an MSDE database on a server "RWPSRV1", and an Access project on
> several clients to track loaner cars. I am attempting to create a PDA based
> return form using Visual Studio.Net. The server will be accessed via a
> wireless network (not web based). I am using the built-in Pocket PC emulator
> that comes with VS.net. for the test -- not an actual PPC. I have a Symbol
> PPT8800 that I can use if necessary.
> >
> > The problem I am having is connecting to the MSDE SQL server. Below is
> the code to a simple form I created to test connectivity with several Dim
> statements I tried. I included all the code but the coonection attempts
> start near the end at "Try". Mostly, the trapped messages state that the
> path is wrong or the server does not exist. The first Dim statement works
> fine (connects) in a windows application form in VS.net -- but not the Smart
> Application.
> >
> > Can someone point out the error(s) of my ways?
> >
> > Is it possible that the emulator does not "connect" but the Symbol (or
> other PPPC) would?
> >
> >
> > Imports System.Data.SqlClient
> > Imports System.Data.SqlServerCe
> >
> > Public Class Form1
> > Inherits System.Windows.Forms.Form
> > Friend WithEvents MainMenu1 As System.Windows.Forms.MainMenu
> >
> > #Region " Windows Form Designer generated code "
> >
> > Public Sub New()
> > MyBase.New()
> >
> > 'This call is required by the Windows Form Designer.
> > InitializeComponent()
> >
> > 'Add any initialization after the InitializeComponent() call
> >
> > End Sub

Re: Connecting Pocket PC to MSDE Sql by Jan

Jan
Tue Jun 01 10:05:56 CDT 2004

>> There are a couple 3rd party tools that people have written that
>> allows you to do this through ADO.
Does any body know what are these 3rd party tools?

>> but he can connect to SQL
>> Server CE and that can link to SQL Server proper
By what means it can be done?

:-)


"kiln" <kiln@brick-like.com> wrote in message
news:MPG.1b25ad47d37045c298987a@msnews.microsoft.com...
> He can't connect from PocketPC to SQL Server, but he can connect to SQL
> Server CE and that can link to SQL Server proper...at least that is my
> understanding, and I don't know if it's of any help to the original
> poster.
>
> In article <#X2keeMREHA.556@tk2msftngp13.phx.gbl>, ks@blah.com says...
> > That is correct .. there is no way to connect to SQLServer from PocketPC
> > directly. There are a couple 3rd party tools that people have written
that
> > allows you to do this through ADO. Basically all they do is open a
socket
> > connection to an application that is running on your server that passes
the
> > data back and forth across the socket.
> >
> > KS
> >
> >
> > "Randy" <anonymous@discussions.microsoft.com> wrote in message
> > news:3E52277B-5A9D-4D43-99A2-E6662E470F21@microsoft.com...
> > > I have an MSDE database on a server "RWPSRV1", and an Access project
on
> > several clients to track loaner cars. I am attempting to create a PDA
based
> > return form using Visual Studio.Net. The server will be accessed via a
> > wireless network (not web based). I am using the built-in Pocket PC
emulator
> > that comes with VS.net. for the test -- not an actual PPC. I have a
Symbol
> > PPT8800 that I can use if necessary.
> > >
> > > The problem I am having is connecting to the MSDE SQL server. Below
is
> > the code to a simple form I created to test connectivity with several
Dim
> > statements I tried. I included all the code but the coonection attempts
> > start near the end at "Try". Mostly, the trapped messages state that
the
> > path is wrong or the server does not exist. The first Dim statement
works
> > fine (connects) in a windows application form in VS.net -- but not the
Smart
> > Application.
> > >
> > > Can someone point out the error(s) of my ways?
> > >
> > > Is it possible that the emulator does not "connect" but the Symbol (or
> > other PPPC) would?
> > >
> > >
> > > Imports System.Data.SqlClient
> > > Imports System.Data.SqlServerCe
> > >
> > > Public Class Form1
> > > Inherits System.Windows.Forms.Form
> > > Friend WithEvents MainMenu1 As System.Windows.Forms.MainMenu
> > >
> > > #Region " Windows Form Designer generated code "
> > >
> > > Public Sub New()
> > > MyBase.New()
> > >
> > > 'This call is required by the Windows Form Designer.
> > > InitializeComponent()
> > >
> > > 'Add any initialization after the InitializeComponent() call
> > >
> > > End Sub



Re: Connecting Pocket PC to MSDE Sql by kiln

kiln
Tue Jun 01 11:51:42 CDT 2004

Hi

I really don't know anything about this area, I'm just starting to
learn, and the MS site info about SQL CE seems to be wrong in some
cases; but I got my impression from the MS SQL CE site. It says:

"Remote data access and merge replication ensure that data from SQL
Server databases is delivered reliably, can be manipulated offline, and
can be synchronized later to the server, making SQL Server CE ideal for
mobile and wireless environments."

That is at

http://www.microsoft.com/sql/ce/productinfo/overview.asp

I hope that it's true anyways...probably there must be more real world
info on this subject on this ng.

In article <#mGSsn#REHA.556@tk2msftngp13.phx.gbl>, transation16
@yahoo.com says...
> >> There are a couple 3rd party tools that people have written that
> >> allows you to do this through ADO.
> Does any body know what are these 3rd party tools?
>
> >> but he can connect to SQL
> >> Server CE and that can link to SQL Server proper
> By what means it can be done?
>
> :-)
>
>
> "kiln" <kiln@brick-like.com> wrote in message
> news:MPG.1b25ad47d37045c298987a@msnews.microsoft.com...
> > He can't connect from PocketPC to SQL Server, but he can connect to SQL
> > Server CE and that can link to SQL Server proper...at least that is my
> > understanding, and I don't know if it's of any help to the original
> > poster.
> >
> > In article <#X2keeMREHA.556@tk2msftngp13.phx.gbl>, ks@blah.com says...
> > > That is correct .. there is no way to connect to SQLServer from PocketPC
> > > directly. There are a couple 3rd party tools that people have written
> that
> > > allows you to do this through ADO. Basically all they do is open a
> socket
> > > connection to an application that is running on your server that passes
> the
> > > data back and forth across the socket.
> > >
> > > KS
> > >
> > >
> > > "Randy" <anonymous@discussions.microsoft.com> wrote in message
> > > news:3E52277B-5A9D-4D43-99A2-E6662E470F21@microsoft.com...
> > > > I have an MSDE database on a server "RWPSRV1", and an Access project
> on
> > > several clients to track loaner cars. I am attempting to create a PDA
> based
> > > return form using Visual Studio.Net. The server will be accessed via a
> > > wireless network (not web based). I am using the built-in Pocket PC
> emulator
> > > that comes with VS.net. for the test -- not an actual PPC. I have a
> Symbol
> > > PPT8800 that I can use if necessary.
> > > >
> > > > The problem I am having is connecting to the MSDE SQL server. Below
> is
> > > the code to a simple form I created to test connectivity with several
> Dim
> > > statements I tried. I included all the code but the coonection attempts
> > > start near the end at "Try". Mostly, the trapped messages state that

Re: Connecting Pocket PC to MSDE Sql by KS

KS
Tue Jun 01 12:13:35 CDT 2004

There is very little documentation on replication on the internet ...
through reading A LOT on the internet on about 20 sites and the newsgroups,
I was finally able to get replication running. The SQL Server replication
wizard does some of the work for you, but you have to have ASP running on
your server along with installing the server side SQLServer CE replication
dll.

I believe someone did write a book on it though ...

KS

"kiln" <kiln@brick-like.com> wrote in message
news:MPG.1b2653f92395449f989881@msnews.microsoft.com...
> Hi
>
> I really don't know anything about this area, I'm just starting to
> learn, and the MS site info about SQL CE seems to be wrong in some
> cases; but I got my impression from the MS SQL CE site. It says:
>
> "Remote data access and merge replication ensure that data from SQL
> Server databases is delivered reliably, can be manipulated offline, and
> can be synchronized later to the server, making SQL Server CE ideal for
> mobile and wireless environments."
>
> That is at
>
> http://www.microsoft.com/sql/ce/productinfo/overview.asp
>
> I hope that it's true anyways...probably there must be more real world
> info on this subject on this ng.
>
> In article <#mGSsn#REHA.556@tk2msftngp13.phx.gbl>, transation16
> @yahoo.com says...
> > >> There are a couple 3rd party tools that people have written that
> > >> allows you to do this through ADO.
> > Does any body know what are these 3rd party tools?
> >
> > >> but he can connect to SQL
> > >> Server CE and that can link to SQL Server proper
> > By what means it can be done?
> >
> > :-)
> >
> >
> > "kiln" <kiln@brick-like.com> wrote in message
> > news:MPG.1b25ad47d37045c298987a@msnews.microsoft.com...
> > > He can't connect from PocketPC to SQL Server, but he can connect to
SQL
> > > Server CE and that can link to SQL Server proper...at least that is my
> > > understanding, and I don't know if it's of any help to the original
> > > poster.
> > >
> > > In article <#X2keeMREHA.556@tk2msftngp13.phx.gbl>, ks@blah.com says...
> > > > That is correct .. there is no way to connect to SQLServer from
PocketPC
> > > > directly. There are a couple 3rd party tools that people have
written
> > that
> > > > allows you to do this through ADO. Basically all they do is open a
> > socket
> > > > connection to an application that is running on your server that
passes
> > the
> > > > data back and forth across the socket.
> > > >
> > > > KS
> > > >
> > > >
> > > > "Randy" <anonymous@discussions.microsoft.com> wrote in message
> > > > news:3E52277B-5A9D-4D43-99A2-E6662E470F21@microsoft.com...
> > > > > I have an MSDE database on a server "RWPSRV1", and an Access
project
> > on
> > > > several clients to track loaner cars. I am attempting to create a
PDA
> > based
> > > > return form using Visual Studio.Net. The server will be accessed
via a
> > > > wireless network (not web based). I am using the built-in Pocket PC
> > emulator
> > > > that comes with VS.net. for the test -- not an actual PPC. I have a
> > Symbol
> > > > PPT8800 that I can use if necessary.
> > > > >
> > > > > The problem I am having is connecting to the MSDE SQL server.
Below
> > is
> > > > the code to a simple form I created to test connectivity with
several
> > Dim
> > > > statements I tried. I included all the code but the coonection
attempts
> > > > start near the end at "Try". Mostly, the trapped messages state
that



Re: Connecting Pocket PC to MSDE Sql by KS

KS
Tue Jun 01 12:30:43 CDT 2004

"Jan Lemeshuk" <transation16@yahoo.com> wrote in message
news:%23mGSsn%23REHA.556@tk2msftngp13.phx.gbl...
> >> There are a couple 3rd party tools that people have written that
> >> allows you to do this through ADO.
> Does any body know what are these 3rd party tools?

Here's one example:

http://www.dbbridge.com/dbbridge/dbbpocketpcmain.htm

> >> but he can connect to SQL
> >> Server CE and that can link to SQL Server proper
> By what means it can be done?

This is not real time ... you'd have to replicate first and do your queries
after replication has been done. Replication is pretty darn quick ... so it
might appear real time to the user ...

KS