Click here to Skip to main content
15,892,059 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have backed up an sql database with vb net 2015 and smo. I want to be able to restore the database with different name. An article I found here is in c# which I am novice.

What I have tried:

I found c# example and had destination name that used to rename. Sorry to ask for code but I cannot find any vb net example. Thank you kyriakod
Posted
Updated 16-Feb-22 2:53am

So use an online converter to translate: Code Converter C# to VB and VB to C# – Telerik[^]
It won't do whole projects, but it should do enough that any competent VB coder should be able to work it out in combination with the MS documentation.
 
Share this answer
 
Have a look at the documentation, it contains quite good example for both backing up and restoring

Backing Up and Restoring Databases and Transaction Logs - SQL Server | Microsoft Docs[^]
 
Share this answer
 
from sql server I restore the database with different name from managment studio
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900