DotNetNewsgroup.com  
web access to complete list of Microsoft.NET newsgroups
   home   |   control panel login   |   archive  |  
 
  carried group
academic
adonet
aspnet
aspnet.announcements
aspnet.buildingcontrols
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
assignment_manager
datatools
dotnet.distributed_apps
dotnet.general
dotnet.myservices
dotnet.nternationalization
dotnet.scripting
dotnet.security
dotnet.vjsharp
dotnet.vsa
dotnet.xml
dotnetfaqs
framework
framework.clr
framework.compactframework
framework.component_services
framework.controls
framework.databinding
framework.drawing
framework.enhancements
framework.interop
framework.odbcnet
framework.performance
framework.remoting
framework.sdk
framework.setup
framework.webservices
framework.windowsforms
framework.wmi
frwk.windowsforms.designtime
lang.csharp
lang.jscript
lang.vb
lang.vb.controls
lang.vb.data
lang.vb.upgrade
lang.vc
lang.vc.libraries
  
 
start date: Fri, 29 Jun 2007 16:12:24 -0400,    posted on: microsoft.public.dotnet.framework.aspnet.security        back       

Thread Index
  1    Juan Romero
          2    Steve


Problem with Login Control   
Hi Guys,

I have setup a SQL 2005 DB with ASP.NET membership tables.

Everything seems to work and I am able to connect to this DB (sitting in
different server) because the WSAT allows me to create users and roles.

However, when I place a login control on the application and hit the login
button I get a connection error:

An error has occurred while establishing a connection to the server.  When
connecting to SQL Server 2005, this failure may be caused by the fact that
under the default settings SQL Server does not allow remote connections.
(provider: Named Pipes Provider, error: 40 - Could not open a connection to
SQL Server)

I have no idea why this happens. As I understand it the provider is defined
in the web config file and the WSAT uses that information for its interface
so theoretically it should work.

Any help would be much appreciated.

Thank you in advance!
Date:Fri, 29 Jun 2007 16:12:24 -0400   Author:  

RE: Problem with Login Control   
The problem is possibly in the membership section of your Web.config.  Check 
it again; make sure it's pointing to the same connection string as the 
profile and role sections.  Here is an example of a membership section I 
often use:
(some of these settings are not secure enough for a public site however; I 
use this for an internal site used only by my team.)

<membership defaultProvider="AppServicesDBMembershipProvider">
<providers>
<remove name="*"/>
<add name="AppServicesDBMembershipProvider" 
connectionStringName="AppDBConnection" enablePasswordRetrieval="false" 
enablePasswordReset="true" requiresQuestionAndAnswer="false" 
applicationName="/" requiresUniqueEmail="false" passwordFormat="Hashed" 
maxInvalidPasswordAttempts="15" minRequiredPasswordLength="4" 
minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10" 
passwordStrengthRegularExpression="" 
type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, 
Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
</providers>
</membership>

"Juan Romero" wrote:


> Hi Guys,
> 
> I have setup a SQL 2005 DB with ASP.NET membership tables.
> 
> Everything seems to work and I am able to connect to this DB (sitting in
> different server) because the WSAT allows me to create users and roles.
> 
> However, when I place a login control on the application and hit the login
> button I get a connection error:
> 
> An error has occurred while establishing a connection to the server.  When
> connecting to SQL Server 2005, this failure may be caused by the fact that
> under the default settings SQL Server does not allow remote connections.
> (provider: Named Pipes Provider, error: 40 - Could not open a connection to
> SQL Server)
> 
> I have no idea why this happens. As I understand it the provider is defined
> in the web config file and the WSAT uses that information for its interface
> so theoretically it should work.
> 
> Any help would be much appreciated.
> 
> Thank you in advance!
> 
> 
> 
> 
> 
Date:Mon, 16 Jul 2007 07:06:04 -0700   Author:  

Google
 
Web dotnetnewsgroup.com


COPYRIGHT ?2005, EUROFRONT WORLDWIDE LTD., ALL RIGHT RESERVE  |   Contact us