I think the problem is that you are trying to do this in a separate SQLExpress database. You may have another copy of AdventureWorks that is actually permanently attached, so you don't see any errors.
Try the following:
1) If you do not already have a copy of SQL Server Management Studio [Express], getting it will be easier to work with than with Visual Studio.
2) Run the following script:
USE AdventureWorks SELECT name, physical_name FROM sys.database_files
3) If you receive an error message indicating that the database does not exist, go to step 5. If you see physical_name entries that do not match the local one in your app_data folder, go to the next step. If you see entries that are in the same app_data folder, then I am puzzled.
4) To disconnect an existing database, follow these steps:
EXEC sp_detach_db 'AdventureWorks'
5) To attach SQL Express DB for your application, do the following:
EXEC sp_attach_db 'AdventureWorks', 'C:\inetpub\wwwroot\MyApp\App_Data\ASPNETDB.MDF', 'C:\inetpub\wwwroot\MyApp\App_Data\ASPNETDB_log.ldf'
6) Run the aspnet_regsql tool again with the same parameters that you originally used, except that do not include .mdf at the end of the database .mdf .
7) Verify in SSMS [E] that the tables have been created.
8) EXEC sp_detach_db 'AdventureWorks' database again using EXEC sp_detach_db 'AdventureWorks' (you will need to do this if the application uses ad-hoc attachment in its connection string, which Iām bidding on).