WebPartManager的一个问题

今天想写一个WebSite程序,在其中加入了一个WebPartManager控件,想玩一下。

结果怎么也跑不起来。

总是说:

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)



搞得我莫名其妙的。Google了好久才知道了原因, 都是WebPartManager里的Personalization属性搞的鬼。缺省它是被设置成TRUE的。启动时候会去找一个数据库实例。

我机器上没有这个数据库实例,所以会失败。


具体的还可以参考 这里。


看来对Web编程还是不熟啊!! 努力!! 

 

posted @ 2008-11-27 13:59  卜海清  阅读(634)  评论(0编辑  收藏  举报