How to do ,About SQL DMO

with like VB code:
 Set objServer = CreateObject("SQLDMO.SQLServer")
 objServer.Connect Text1.Text, Text2.Text, Text3.Text
 For Each objTable In objServer.Databases("NCZZB_XJSH_DATA").Tables
  objTable.Script , "d:\az\" & objTable.Name & ".sql"
  objTable.Triggers.Scpipt , "d:\az\" & objTable.Name & ".sql"
 Next
 objServer.DisConnect
 Set objServer = Nothing

How to Do by Delphi?

I need a DEMO.
LannyKing66Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

LannyKing66Author Commented:
Help me!
0
halapayaCommented:
same concept use delphis createoleobject method,

var
Server:variant;
Databases:Variant;
Server:=createoleobject('SQLDMO.SQLServer');

Server.Connect "server","login","pass"

for i := 0 to Servers.Databasescount-1 do
begin
'keep on coding :o)
end

same way you use the methods. just define as variants and keep on calling objects methods and properties
for more information on sqldmo methods and object model check the sqldmo.hlp file in mssql7\binn directory..

its quite striaght forward to do with delphi also..
if u need any help drop me a mail on moditha@yahoo.com
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Delphi

From novice to tech pro — start learning today.