[RESOLVED]webpartzone issue

 I’ve  added in a WebPartManager to my web page, and when I view in browser, it throws the following error: 

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)

When I set personalization to false,it works fine, but I need to display it in designmode, so I need to have personalization =true.

How to be?

Hi,

WebPart personalization uses ASPNETDB.mdf to store the personlized data.. You would need to install SQL Express first before using WebParts.. 

Check this thread for same issue:

http://forums.asp.net/t/1355323.aspx

http://forums.asp.net/p/1334649/2687978.aspx

ASP.NET has a default connection string called "LocalSqlServer", which creates the mdf file. To disable this, you can add <clear /> as the first item in the ConnectionStrings element in web.config. After that you can either add a new connection string with
that namn, but your connection string, or you can add one with another name. If you user your own name you need to specify that for the membership provider, profile provider etc in web.config.

WebPart personalization uses ASPNETDB.mdf to store the personlized data.. so be sure that your application is also pointing to ASP.NETDB when deploying so that you will be able to use WebParts personalization. See this thread:
http://forums.asp.net/p/1400394/3037294.aspx

Leave a Reply