Connect to SqlServer2000 from the emulator

  • Thread starter Thread starter Zanna
  • Start date Start date
Z

Zanna

Hi all!

Why I cannot connect to a SqlServer from the emulator?

It always says that the Sql server does not exist!

Thanks
 
It is possible to connect to SqlServer from an emulator.

You'll need to provide a sample of your connection
string and information about your machine name, the
server name, db instance, and network topology to
answer this question completely, but in many cases,
referring to the SqlServer by IP address in your connection
string will work when referring to it by name will not. I'm
assuming you have the networking in your emulator setup
correctly as well.
--
Darren Shaffer
..NET Compact Framework MVP
Principal Architect
Connected Innovation
www.connectedinnovation.com
 
You'll need to provide a sample of your connection
string and information about your machine name, the
server name, db instance, and network topology to
answer this question completely,

Simply:

str = "Server=MyMachineName;DataBase=DbName;User Id=sa;Password="
dbSql = New System.Data.SqlClient.SqlConnection(str)
dbSql.Open()

My machine name is the same and the server name is the same: I'm trying to
connect to a MSDE DB on the same machine of the emulator and VS.

MSDE is configured for mixed access.
but in many cases,
referring to the SqlServer by IP address in your connection
string will work when referring to it by name will not.

Ok, what is the right IP I should use?
If I'm working on a stand-alone PC?
I'm
assuming you have the networking in your emulator setup
correctly as well.

What are the right settings for the emulator?
I have to set some network adapter?
I can see the PC shared folders from the "explorer" if I open \\MyPcName.

Thanks.
 
The 'standalone PC' is the problem. You must have a network connection of
some sort. In this case download and install the Microsoft loopback
adapter.

-Chris
 
The 'standalone PC' is the problem. You must have a network connection of
some sort. In this case download and install the Microsoft loopback
adapter.

I've already installed the loopback adapter.
There is some setup I must follow?

I have similar problem also on a LAN: sometime it connects, sometime it
doesn't :(
 
If the name of the emulator is Pocket_PC change it to something else in
order to have network connectivity.

Marius
 
Zanna,

I don't know if this applies to the emulator, but when working with a
wireless network and a device opening Sql Server from CF, will be prevented
by the Window's firewall - in SP2. eg "Sql server doesn't exist or access
denied". You will need to create an exception in the window's firewall
control applet for your instance of SqlServer to allow the connection to
open.

I presume this also applies if doing Sql rda or replication wirelessly, but
I haven't tested those.

Graham
 
Back
Top