Board index » delphi » Creating new aliases in BDE without running BDECFG?

Creating new aliases in BDE without running BDECFG?

Does anybody know how to create a new alias or modify an old one without
running the BDECFG?

I would greately appreciate any info on this subject!
Thank's!
Olov Arvidsson, PC medical, Denmark
e-mail: em...@pcmedical.dk

 

Re:Creating new aliases in BDE without running BDECFG?


In article <01bbc7f4$ce1bd9e0$0200a8c0@OLOV>, From "Olov Arvidsson"
<em...@pcmedical.dk>, the following was written:

Quote
> Does anybody know how to create a new alias or modify an old one
> without running the BDECFG?

> I would greately appreciate any info on this subject!
> Thank's!
> Olov Arvidsson

Hi Olov,

Take a look at the TSession component and the methods:

AddAlias, AddStandardAlias, DeleteAlias, SaveConfigFile

Following will create a alias and save it in the BDE config file:

procedure TForm1.Button1Click(Sender: TObject);
begin
      with Session do
      begin
        ConfigMode := cmPersistent;
        try
          AddStandardAlias('MyAlias', ExtractFilePath(ParamStr(0)),
'PARADOX');           SaveConfigFile;
        finally
          ConfigMode := cmAll;
        end;
      end;
end;

Hope this helps and God Bless,

--
Jay Schwisow j...@weldnet.com
11/01/96 21:35
---------
Using: OUI PRO 1.5.0.2 from http://www.dvorak.com

Re:Creating new aliases in BDE without running BDECFG?


Quote
Olov Arvidsson wrote:

> Does anybody know how to create a new alias or modify an old one
> without running the BDECFG?

  Simple, don't use Aliases...  None of my databases do.  All you have
to do is load everything at run-time....

--
Jason
E...@DarkElf.reno.nv.us

Other Threads