Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Backup Class Not Showing in Microsoft.SqlServer.Management.Smo Reference

I want to add Backup and Restore Functionality in C# Windows Form Application. for this i inserted

Microsoft.SqlServer.Management.Smo reference in my code.. but I can't see the Backup and Restore classes in this reference.

like image 948
Arslan Khalid Avatar asked Jan 20 '26 00:01

Arslan Khalid


1 Answers

I found the answer by my self. and that is

for using Backup and restore class of SMO we need to 5 reffereces.

Go to Your Application and Right Click on References folder and select Add Reference.

Now Go to "Browse" Tab and browse the following path- C:\Program Files\Microsoft SQL Server\110\SDK\Assemblies

Now Select the following dlls

  • Microsoft.SqlServer.ConnectionInfo.dll
  • Microsoft.SqlServer.Management.Sdk.Sfc.dll
  • Microsoft.SqlServer.Smo.dll
  • Microsoft.SqlServer.SmoExtended.dll
  • Microsoft.SqlServer.SqlEnum.dll

I have added only this (Microsoft.SqlServer.Smo.dll) reference first but for Backup and Restore classes we also need this (Microsoft.SqlServer.SmoExtended.dll) reference

like image 200
Arslan Khalid Avatar answered Jan 22 '26 13:01

Arslan Khalid



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!