Board index » delphi » Unknown Database alias error.

Unknown Database alias error.

I have a D5 Paradox app converted from D3. Until now I have not
needed to install Aliases since I used a TDatabase component
whose parameters get set at run-time to the data path (thus
allowing for different databases on the same machine). This
worked fine in D3 but now I have converted to D5 I get an
unknown database alias error.
Has their been some change in D4or D5 that causes this change in
behaviour?

How should I use a Tdatabase in D5 without using an alias as I
did in D3?

I currently have a TDatabase with no alias set but do the
following at run-time

Pat Bell

 

Re:Unknown Database alias error.


One time I had a problem with aliases and
it turned out to be how the operating system/delphi
was handling "cases" in a new version.  Try switching
to all lower case if its not lower case now.

Also, you could do what you are doing but still
use aliases.  That's what I do.

Quote
"P.S.Bell" <p...@PatBell.demon.co.uk> wrote in message

news:VA.0000028c.054dc22b@patbell.demon.co.uk...
Quote
> I have a D5 Paradox app converted from D3. Until now I have not
> needed to install Aliases since I used a TDatabase component
> whose parameters get set at run-time to the data path (thus
> allowing for different databases on the same machine). This
> worked fine in D3 but now I have converted to D5 I get an
> unknown database alias error.

> Has their been some change in D4or D5 that causes this change in
> behaviour?

> How should I use a Tdatabase in D5 without using an alias as I
> did in D3?

> I currently have a TDatabase with no alias set but do the
> following at run-time

> Pat Bell

Re:Unknown Database alias error.


Make sure that you don't have any datasets open at design time.

I do the exactly the same as you in my Delphi 3 app, and occasionally I
set a table active at design time to see how a grid will look, and then
forget to set it back.  If it is on a form that is auto-created (mine
normally aren't, but I sometimes forget that as well), then I get the same
error as you.

--Bill Sparrow--

Re:Unknown Database alias error.


D5 should work exactly like D3 in this regard. Make sure that _all_ datasets
are closed and the Connected property of the TDatabase is set to False at
design time.

--
Bill Todd (TeamB)
(Questions received via email cannot be answered.)

Other Threads