Sudden error on connection, conflict sql 2000-2005? desperated!

P

Pieter

Hi,


I have some nasty error when deploying my application (VB.NET 20002) on the
users-computers. I'm using an SQL 2000 database.

The problem I guess is the fact that I had a local SQL 2000 and a local SQL
2005. I used to develop on a network SQL 2000 (the same which the users are
connecting too), and everything works fine. But now I am not in the office
for 2 weeks, so I have to develop on my local SQL 2000 instance. I send them
the exectuable, and this is what they get:

"An error has occurred while establishing a connection to the server. When
connecting to SQL Server 2005, this failure may be caused by the fact that
under the default settings SQL Server does not allow remote connections.
(provider: Named Pipes Provider, error: 40 - Could not open a connection to
SQL Server)"

I only gave them a new exectuable, the App.Config didn't change.

anybody gets any idea? I'm getting kind of desperated. I desinstalled SQL
2000 AND SQL 2005, and re-installed only SQL 2000. But I still get the
error.

Anybody any idea, any hints?

Thanks a lot in advance!

Pieter
 
A

Alan Pretre

Pieter said:
"An error has occurred while establishing a connection to the server.
When connecting to SQL Server 2005, this failure may be caused by the fact
that under the default settings SQL Server does not allow remote
connections. (provider: Named Pipes Provider, error: 40 - Could not open a
connection to SQL Server)"
anybody gets any idea? I'm getting kind of desperated. I desinstalled SQL
2000 AND SQL 2005, and re-installed only SQL 2000. But I still get the
error.

Yes, we have seen this at our office. I believe you have to go into SQL
2005 config and enable TCP/IP connections. This gets turned off for some
reason in the upgrade.

-- Alan
 
P

Pieter

But I'm not using SQL 2005 at all! The users are connecting to a SQL 2000
database! :-S
And everything worked fine before, it just this week that it broke down...
 
A

Alan Pretre

Pieter said:
But I'm not using SQL 2005 at all! The users are connecting to a SQL 2000
database! :-S
And everything worked fine before, it just this week that it broke down...

Try checking the settings anyway. This sounds like the error we saw here.
In SQL 2000, go into SQL Server Client Network Utility and see if TCP/IP and
Named Pipes are enabled.

-- Alan
 
P

Pieter

Ok, I found the problem: The connectionstring was just not right: it was
poiting to my local SQL Server, which they can not access there offcourse
:)
Although I don't get it yet how this could happen:
I'm using the Settings.settings of VB.NET to define a Connectionstring
(Scope = application). But it seems that this value is hardcoded somewhere
in the application? I had a App.Config in which it had the right value, but
that value isn't used?

I'm really getting confused now :-S It seems that I must take a better look
to the Settings.settings, because it doesn't react as I expected :)

thanks anyways,

Pieter
 
J

Jay Pondy

I saw a similar problem when I changed a setting in App.Config instead
of the Settings page in Beta2. The Settings reflected what I changed
during design time but at run time it went back to what was there
before. Took me forever to track it down.
 
P

Pieter

And did you find a solution for it? I mean: I just want it to behave like
the 'old' App.Config: when I open the file in Notepad and I change the
ConnectionString, it should use that value. How do I accomplish that?
 
J

Jay Pondy

The problem I had occurred inside the IDE.

After re-reading your description I take it that your problem is
occurring on clients AFTER the app has been deployed and you have
modified the Clients App.Config file?
 
P

Pieter

Jay Pondy said:
The problem I had occurred inside the IDE.

After re-reading your description I take it that your problem is
occurring on clients AFTER the app has been deployed and you have
modified the Clients App.Config file?

Yes indeed :) It's after deployment, and the changed value in the
App.Config isn't used :-/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top