Re: SQLDataConnection

From: Jay Walters (anonymous_at_discussions.microsoft.com)
Date: 06/04/04


Date: Thu, 3 Jun 2004 20:10:18 -0700

I don't think that's what he was trying to do :-)

I think he's a total newbie and just doesn't have a
proper connection string...

The error is : >> Login failed for user '(null)'.

If he was having trouble connecting with the ASPNET
account - it would say failed for <LOCAL>\ASPNET

>-----Original Message-----
>First uncheck anonymous access in directory security tab
of IIS, then in
>web.config put element <impersonate="true"> that will
allow to connect to
>SQL server under your account.
>
>Regards,
>Daniel
>"Papri Chakravorty"
<anonymous@discussions.microsoft.com> wrote in message
>news:D477AE02-7FE5-4751-B172-
1C1EA047752C@microsoft.com...
>> hello,
>> I have been trying to test a code to connect to an
sqlserver database.
>> all i have done is used a datagrid to display some
data from pubs databse
>in sqlserver.
>> i have used sqlconnection, sqldataadapter. i have
writted code under page
>load as
>> sqldataadapter1.fill(dataset1)
>> datagrid1.databind().
>> when i build and browse the page, I get the message,
>> Login failed for user '(null)'. Reason: Not associated
with a trusted SQL
>Server connection.
>> Can you guys explain what is happening? It is really
frustrating.
>> Thanks Papri
>
>
>.
>