Migration of Online Form created in Expression Web

S Pramanik 1 Reputation point
2021-08-19T13:40:43.833+00:00

I need to change the Access Database connection to SQL Database server connection in Online Form created in Expression Web. The files are .asp not .aspx. Can that be done in EW? Following is the driver need to be replaced.

strConn="Driver={Microsoft Access Driver (*.mdb, *.accdb)};Dbq=d:\websurveys\xyz.accdb;Uid=;Pwd=;"

Set conn = Server.CreateObject("ADODB.Connection")
conn.Open strConn

ANY HELP IS HIGHLY AI need to change the Access Database connection to SQL Database server connection in Online Form created in Expression Web. The files are .asp not .aspx. Can that be done in EW? Following is the driver need to be replaced.

strConn="Driver={Microsoft Access Driver (*.mdb, *.accdb)};Dbq=d:\websurveys\xyz.accdb;Uid=;Pwd=;"

Set conn = Server.CreateObject("ADODB.Connection")
conn.Open strConn

Do I need to rebuild the forms in Visual Studio? Any help is highly appreciated.

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
13,361 questions
{count} votes

5 answers

Sort by: Most helpful
  1. Michael Taylor 51,346 Reputation points
    2021-08-19T14:25:50.767+00:00

    Change the strConn variable. I'm guessing at the syntax but the docs are here.

       strConn = "Provider=SQLOLEDB;Data Source='MySqlServer';Initial Catalog='MyDatabase';Integrated Security='SSPI;"  
    

    Note that SQL syntax between Access and SQL is different so you'll also need to adjust all your queries accordingly.

    Since you have the connection string hard coded in your code then yes you'll need to rebuild it but I don't think Visual Studio supports ASP anymore. That is several decades old code. It does support ASPX which has far better support but that would be a huge change to transition from Classic ASP to ASPX.

    But the other thing I'm wondering about is Expression Web. The only context I've heard of the product for is ASPX so mentioning ASP is odd.

    0 comments No comments

  2. S Pramanik 1 Reputation point
    2021-08-19T18:15:16.077+00:00

    Thanks for your answer. My question is if I change the connection string and queries and leave the file as .asp, will it work?

    Since the website was buit using Expression Web, if the forms built in future in Visual Studio, what the best option is to use Visual Basic WebForm or Visual C#?


  3. S Pramanik 1 Reputation point
    2021-08-19T18:50:05.427+00:00

    If the website was developed in EW and all the existing pages and forms are not migrated, how ASP.NET C# Web Form works?


  4. S Pramanik 1 Reputation point
    2021-08-19T19:54:29.483+00:00

    The website created in EW is heavily used, so migrating will be time consuming. But if I create the new form using ASP.NET C# and can it be deployed as .aspx application from the existing website?


  5. Seeya Xi-MSFT 16,461 Reputation points
    2021-08-20T06:27:57.15+00:00

    Hi @S Pramanik ,

    Here is the steps: https://www.engineeredit.com/database-consulting/convert-access-to-web
    Hope this is useful.

    Best regards,
    Seeya


    If the response is helpful, please click "Accept Answer" and upvote it, as this could help other community members looking for similar queries.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    0 comments No comments