DB connection problem in attemp to load DataGrid from SQLServer DB

From: Richard Lionheart (NoOne_at_Nowhere.net)
Date: 09/14/05


Date: Tue, 13 Sep 2005 19:14:30 -0400

Hi All,

I originally (and mistakenly) posted this on
microsoft.public.dotnet.framework.windowsforms I hope this time I've posted
it on more appropriate newsgroups.

I'm trying to run Jeff Prosise's DataGrid example in Chapter 6 of
"Programming Microsoft .NET".

Jeff provided a MyComics.sql file which I've used in Query Analyzer to
create and populate a MyComics database in SQLServer 7.0 installed with NT
authentication. I verified that the table had been loaded correctly with a
Select statement.

IE displayed the following info:

============================
Exception Details: System.Data.SqlClient.SqlException: Login failed for user
'sa'. Reason: Not associated with a trusted SQL Server connection.

Source Error:

Line 70:
"server=localhost;database=mycomics;uid=sa;pwd=xxxxx");
Line 71: DataSet ds = new DataSet ();
Line 72: adapter.Fill (ds);
Line 73: MyDataGrid.DataSource = ds;
Line 74: MyDataGrid.DataBind ();

Source File: f:\inetpub\wwwroot\DataGrid-Prosise.Comics.aspx Line: 72
================================

I exex out the password. I'm quite sure the password I had supplied was
correct for the "sa" account.

I suspect the problem is a conflict between my specification of NT
authentication and the example's use of the "sa" user. I also tried
removing the uid/pswd to no effect.

Any ideas? Should I post this stuff in some security NG instead?

Thanks in advance,
Richard



Relevant Pages

  • Re: Implementation of Online Update feature
    ... As I stated, I blocked "Jeff", so I couldn't read his reply (or replies) directly. ... My "complaint" is that these newsgroups are intended for peer to peer support and you're using them soley as a means to "advertise" your products. ... advertising/solicitation are not what the newsgroups are intended for. ...
    (microsoft.public.vb.winapi)
  • Re: installing xp home
    ... Jeff, sorry to have to tell you this, but Andrew E. is a well-known ... troll in these newsgroups, and usually posts nonsense, and often ... It is always safe to ignore anything Andrew E. says. ... full version and wanted to do a clean install so I used the me boot disk and ...
    (microsoft.public.windowsxp.newusers)
  • RE: Web Forms Auth fails when rfValidator triggered
    ... | basically has a username field, ... | If I enter garbage text in BOTH fields, the authentication ... | controls do their job and display the "error text" stating ... | Jeff Ptak ...
    (microsoft.public.dotnet.framework.aspnet.security)
  • Re: Ritalin covert agenda
    ... >Jan's post has had the newsgroups restored. ... Jeff does not read mha. ... Tell that to the children who benefit from treatments for ADHD. ... Of course, as with any medication, the risks and benefits must be weighed, ...
    (sci.med)
  • Re: Outlook Express &SP2
    ... > pro 5.0 I created an exception for the Windows firewall ... > would be appreciated,Thanks Jeff ... This is a group to support Outlook from the Office group of programs. ... for all the microsoft.public newsgroups). ...
    (microsoft.public.outlook.general)