Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opendialog for a database/aliasname 1

Status
Not open for further replies.

Karen99

Programmer
Aug 5, 2003
113
ZA
My user can select to which database he wants to connect. I just change the aliasname of my TDatabase. Does anyone know of a way for me to list al the aliasnames for my user. I can not hardcode a list, because I don't know what it will be beforehand for each user. I need something like a TOpendialog for databases. Or can somebody suggest something else ?
 
Taking this straight from the Delphi 5 Help files :

MyStringList := TStringList.Create;

try
Session.GetAliasNames(MyStringList);
{ fill a list box with alias names for the user to select from }
for I := 0 to MyStringList.Count - 1 do
ListBox1.Items.Add(MyStringList);
finally
MyStringList.Free;
end;

Maybe this could be the start of the concept for you ?
Hope that this helps.
Steve
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top