Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Not associated with a trusted Sql Server connection.
Message
De
17/10/2002 16:30:56
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Bases de données
Titre:
Not associated with a trusted Sql Server connection.
Divers
Thread ID:
00712577
Message ID:
00712577
Vues:
34
Hi

I add manually a database "Test" and created a table "TableTest" with Server Explorer
in the same SQL Server instance [COMPUTERNAME] that database "master"

// C# sample

private void buttonConnect_Click(object sender, System.EventArgs e)
{
string sConnection = "Data Source =(local);Initial Catalog =TEST" +
"User Id=Owner ;Password=" ;

System.Data.SqlClient.SqlConnection oCon
= new System.Data.SqlClient.SqlConnection(sConnection) ;

try
{
oCon.Open();
}
catch(Exception eExc)
{
MessageBox.Show( eExc.ToString() ) ;

}
finally {
MessageBox.Show("Can't open connection","Form1 message error") ;

}
}


When my application run this method I have the next error message

error:
System.Data.sqllient.SqlException: Login failed for use 'Owner'.
Reason : Not associated with a trusted Sql Server connection.


Used SQL Server login "use Window NT Intregrated Security " option

using : XP Home, Data MSDE , Visual Studio .net and C#


How can I solve this simple problem ?


Thanks You

Roger
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform