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.

Re: Connection Fails? by Joe

Joe
Sat Jul 12 13:51:34 CDT 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" <jwrugo@patmedia.net> wrote in message
news:e24eUh9RDHA.2236@tk2msftngp13.phx.gbl...
> 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.
>
>



Re: Connection Fails? by JWR

JWR
Sun Jul 13 07:24:42 CDT 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" <jfallon1@nospamtwcny.rr.com> wrote in message
news:ucoPEaKSDHA.304@tk2msftngp13.phx.gbl...
> 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" <jwrugo@patmedia.net> wrote in message
> news:e24eUh9RDHA.2236@tk2msftngp13.phx.gbl...
> > 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.
> >
> >
>
>