I wanna connect with aspnetdb however it bakes an error states "Login unsuccessful for user" this is actually the connection string in web config :

<add name="UserProfiles" connectionString="Data Source=KIA;Initial Catalog=aspnetdb;Integrated Security=True;"
   providerName="System.Data.SqlClient" />

which is my code:

SqlConnection connection = new SqlConnection();
        SqlCommand ComNewCheckSum = new SqlCommand();
        connection.ConnectionString = ConfigurationManager.ConnectionStrings["UserProfiles"].ConnectionString;
        connection.Open();
ComNewCheckSum.Connection = connection;
            ComNewCheckSum.CommandText = String.Format("select UserID from aspnet_Users where UserName = {0}", _UserName);

            return Convert.ToInt32(ComNewCheckSum.ExecuteScalar());

how do i go through error? thank

Inside your connection string you're using "Integrated Security=True", and that means you are attempting to connect with this database making use of your Home windows qualifications so it appears aren't good to gain access to this database.

Use a person and password you know get access to this database increase your connections string therefore it uses that information - example:

<add name="UserProfiles" connectionString="Data Source=KIA;Initial Catalog=aspnetdb;User ID=someuser;Password=somepassword;"
   providerName="System.Data.SqlClient" />