简体   繁体   中英

How to add microsoft.sqlserver.smo?

I was trying to create a new database in WebMatrix, and I was shown this error: "Could not load file or assembly "Microsoft.SqlServer.Smo, Version=11.0.0.0, Culture=Neutral, PublicKeyToken=blablabla" or one of its dependencies. System cannot find the file specified.

I am sure that there is some error in SQL Server, but I am not getting help from anyone.

I have already searched alot for this issue. But the main thing is they are all providing help solutions for Visual Studio, none of them are giving some example for web.config or should I say for WebMatrix, I know in VS its pretty simple and easy, but what about WebMatrix?

All that I came upto is somelike in web.config under assemblies, but how to connect it? Or if it is there, how to check whether the file is on system or not?

My question basically is just to know whether the file is in the system; it was installed correctly of not, and to connect it to the project to create new Databases.

Nobody helped I guess! So I tried to find the answer myself. What I found on some other forums was this:

That the dlls are found under this folder:

C:\Program Files\Microsoft SQL Server\100\SDK\Assemblies

And to add them in your site, using WebMatrix will Require some Helper; because I use WebMatrix not Visual Studio.

So for that I will require something:

@using Helper.Name;

The issue for me was that the dll was not installed in Windows 8. And was not able to run so the exception showed up.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM