PC Review


Reply
Thread Tools Rate Thread

Connection Fails?

 
 
JWR
Guest
Posts: n/a
 
      11th Jul 2003
Hi all,
I am trying to track down a connection problem.

VB.NET
SQL2000
ADO.NET

When running the application I get an error say that "the connection string
is empty". I am declaring the variable that holds the connection string in
a Module : Friend ConnStr$ = ""

A dialog box pops up, by design, that allows one to enter login/pwd info and
connect to this SQL Server. This works fine. This box pops up after the
initial error message. Everything after the initial error message runs
great!

I tried debugging and stepping into and over the code but this error pops up
before the code even starts. None of this type of programming is new to me
yet I can't for the life of me understand, or find, where this error is
coming from. If I initialize the ConnStr$ = "<connection string stuff>",
then I do not see an error.

Any ideas where to look would be appreciated.
Thanks,
John.


 
Reply With Quote
 
 
 
 
Joe Fallon
Guest
Posts: n/a
 
      12th Jul 2003
What is the error message?

Debug the entire app.
Start with Sub Main and step through it until you get the error.

In my module I have:
Public connString As String

When the user clicks my Log-On button I compute the string based on their
input values:
connString = "data source=" & Me.txtServer.Text & ";initial catalog=" &
Me.txtDatabase.Text & ";user id=" & Me.txtUID.Text & ";password=" &
Me.txtPwd.Text & ";Connect Timeout=10"
--
Joe Fallon



"JWR" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Hi all,
> I am trying to track down a connection problem.
>
> VB.NET
> SQL2000
> ADO.NET
>
> When running the application I get an error say that "the connection

string
> is empty". I am declaring the variable that holds the connection string

in
> a Module : Friend ConnStr$ = ""
>
> A dialog box pops up, by design, that allows one to enter login/pwd info

and
> connect to this SQL Server. This works fine. This box pops up after the
> initial error message. Everything after the initial error message runs
> great!
>
> I tried debugging and stepping into and over the code but this error pops

up
> before the code even starts. None of this type of programming is new to me
> yet I can't for the life of me understand, or find, where this error is
> coming from. If I initialize the ConnStr$ = "<connection string stuff>",
> then I do not see an error.
>
> Any ideas where to look would be appreciated.
> Thanks,
> John.
>
>



 
Reply With Quote
 
JWR
Guest
Posts: n/a
 
      13th Jul 2003
The exact error message is: "System Error: The ConnectionString property
has not been initialized."

I have tried starting with Sub Main; but the error comes up before Sub Main
starts. That's one of the strange things I can't figure out?


"Joe Fallon" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> What is the error message?
>
> Debug the entire app.
> Start with Sub Main and step through it until you get the error.
>
> In my module I have:
> Public connString As String
>
> When the user clicks my Log-On button I compute the string based on their
> input values:
> connString = "data source=" & Me.txtServer.Text & ";initial catalog=" &
> Me.txtDatabase.Text & ";user id=" & Me.txtUID.Text & ";password=" &
> Me.txtPwd.Text & ";Connect Timeout=10"
> --
> Joe Fallon
>
>
>
> "JWR" <(E-Mail Removed)> wrote in message
> news:(E-Mail Removed)...
> > Hi all,
> > I am trying to track down a connection problem.
> >
> > VB.NET
> > SQL2000
> > ADO.NET
> >
> > When running the application I get an error say that "the connection

> string
> > is empty". I am declaring the variable that holds the connection string

> in
> > a Module : Friend ConnStr$ = ""
> >
> > A dialog box pops up, by design, that allows one to enter login/pwd info

> and
> > connect to this SQL Server. This works fine. This box pops up after

the
> > initial error message. Everything after the initial error message runs
> > great!
> >
> > I tried debugging and stepping into and over the code but this error

pops
> up
> > before the code even starts. None of this type of programming is new to

me
> > yet I can't for the life of me understand, or find, where this error is
> > coming from. If I initialize the ConnStr$ = "<connection string

stuff>",
> > then I do not see an error.
> >
> > Any ideas where to look would be appreciated.
> > Thanks,
> > John.
> >
> >

>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Wired connection lost when wireless connection fails =?Utf-8?B?U3RldmUgQnJhbmNo?= Windows XP Networking 0 28th Sep 2006 02:23 AM
Connection to GC fails with Login Failure leading to account lockout whereas LDAP connection to same domain works Yogesh Patil Microsoft Windows 2000 Active Directory 0 20th Jul 2005 01:56 PM
Drops Connection then fails Dial Up Connection? =?Utf-8?B?Rm9TNjA1?= Windows XP Help 3 10th Apr 2005 04:29 PM
Windows update fails, freezes, fails to logon on hotmail, fails to send mail from outlook express, windows update errors, router settings, "MTU , Partial Loss of Internet Connection, and Performance" stevan Windows XP General 0 9th Aug 2004 07:08 PM
Connection to SQL fails, OK from ASP and VS.NET Tom Kaminski [MVP] Microsoft ASP .NET 2 6th Nov 2003 02:51 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:13 PM.