Question: My conection string was

```
string connStr = @"Data Source=(local)\SQLEXPRESS
                        Initial Catalog=University11;
                        Integrated Security=True";

```

But then I copied my database to

```
C:\Users\Чак\Desktop\ботанизм\ООП\coursework.start\CourseWorkFinal\CourseWorkFinal\

```

And set it as the way in connection string

```
  string connStr = @"Data Source=C:\Users\Чак\Desktop\ботанизм\ООП\coursework.start\CourseWorkFinal\CourseWorkFinal\;
                        Initial Catalog=University11;
                        Integrated Security=True";

```

But in that case I had an exception

```
A network-related or instance-specific error occurred while establishing a connection 
to SQL Server. The server was not found or was not accessible. Verify that the instance 
name is correct and that SQL Server is configured to allow remote connections. 
(provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance 
Specified)

```

What correct connection string do I need?

Answer: 
If that is intended to be a "user instance" access to a file, then the connection string is more like:

```
Data Source=.\SQLEXPRESS;AttachDBFilename=YourPath.mdf;Integrated Security=True;

```

Otherwise, use the Initial Catalog to supply a database name registered on the instance.
I think you shouldn't change your connention string, you can't access SQL SERVER database directly you must always pass through the SQL SERVER DBMS. The only thing you can do is import/export your data or manage your SQL SERVER to read your database from the new destination folder (but this must be done within SQL SERVER not modifying the connection string).