SQLDMO Unhandled Exception

J

Juan

Helo,

I'me developing a proyect wich gets connected to SQL Server. I wished to
show a list of SQL Servers on my networks if the configuration file couldn't
be found...

I can do this using SQLDMO, but it will raise an unhandled exception on any
machine that lacks of a SQL Server... My goal is to list all the servers for
a client application, herefore installing MSDE on the client machines seems
unacceptable (This was a proposed solution on a thread I read on Google). Is
there anyway I can use SQLDMO without installing a SQL Server? If so, how
could it be done?

On the other hand I developped a small walkarround using the Sockets
namespace to create an UDP client in order to search for databases, although
I think it's not as reliable as SQLDMO, therefore I would preffer using
SQLDMO.

The error I get is an Unregistered or invalid COM... In my setup proyect
I've marked SQLDMO.DLL to register as COM.

Hope someone can give me some clues on how to get it to work.

Best wishes
 
G

Guest

Juan,

I am fairly certain you are not allowed to distribute SQL DMO. I remember
this being a topic sometime ago and I am sure the outcome is you can't. I
can't find the original thread but a quick Google search might throw
something up.

Chris.
 
J

Juan Pedro Gonzalez

Helo Chris,

I solved the problem registering the components, although I'm now really
interested on the topic about "distributing" SQL DMO.

In my case I think it's not really distributing SQL DMO, since the
application is being developped with am original SQL Server Enterprise and
Personal edition, and the customer for whom we are developing owns an
original SQL Server Enterprise. Therefore, in my humble opinion, it's not
really a distribution of SQL DMO, just an easier way to deploy the
application inside the customer's enterprise. I really don't care that mucho
on using SQL DMO, NetServersEnum, o my own implementation of NetServerEnum +
Registry search class (Although the last one worries me due to the time outs
I've stablished for UDP broadcast). Although now I've found the way to
deploy SQL DMO it would be nice to use it, but if it can't be used it would
be nice to know in order to follow one path or the other.

Best wishes

Juan
 
J

Juan Pedro Gonzalez

Thank you,

I'll also post here my walkaround although Mirosoft's should be more
complete as it has more files...

I created a Setup Project and added the followin files to:

Programs Files Directory\Microsoft SQL Server\80\Tools\Binn

* sqldmo.dll
* sqlresld.dll
* sqlsvc.dll
* w95scm.dll

Then, under:

Programs Files Directory\Microsoft SQL Server\80\Tools\Binn\Resources\1033
and
Programs Files Directory\Microsoft SQL Server\80\Tools\Binn\Resources\1034

I copied the files (from the proper resource foder)
* sqldmo.rll
* sqlsvc.rll

Dependency walker wouldn't detect any missing files, and sqldmo.dll seemed
to register fine with vsdrfComSelfReg (or Regsvr32).

Tried the setup file on two computers with no client or server installed and
it worked fine. The folder I choosed to install SQLDMO was the same path
where I've got it on my computer just in case, I didn't want to mess thing
up if something went wrong.

Best wishes
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top