Quote:
I just want to change the connection only
and the code remain as it is
Impossible.
You've written your code against SQL Server using objects that are specific to SQL Server, SqlConnection, SqlCommand, SqlDataAdapter, ... Sqlxxxx, whatever.
You have to change ALL of that code to use Access instead, which uses OleDbConnection, OleDbCommand, OleDbDataAdapter, ..., OleDbxxxx.
Oh, and don't get the idea to just search and replace "Sql" with "OleDb". That's not going to save you any work either. The SQL statements themselves may also have to be rewritten, and parameter types changed.
Now, if you've used Entity Framework to handle all of your database activity, you cannot use Access at all. It's not supported.
Access is not a full implementation of SQL. It's a subset of TSQL, with extensions specific to Access.