hello everyone
im creating one application there is have one task that is i want to show multiple users birthday reminder of birthday particular date that value should show in label if suppose two users have same birthday date then that value show like "Ramesh sharma,Suresh verma" im searching lots of blog bt didnt help me .. hope u all getting my question
Loading
Atul RokadePosted Jan 16, 2013, 11:51 AM
for refernce of that project i wrote this code
con = new SqlConnection("Data Source=ADMIN\\SQLEXPRESS;Initial Catalog=PhysioCure; Integrated Security=true");
con.Open();
DateTime dtmain = System.DateTime.Now;
cmd = new SqlCommand("select PationName,ContactNo from Physio_cureTable where DateOfBirth like '" + dtmain.Date.ToString().Substring(0, 5) + "%'", con);
SqlDataReader reader = cmd.ExecuteReader();
while (reader.Read())
{
label18.Name = reader.GetInt32(0).ToString();
label18.Text = reader.GetString(3).ToUpper();
label19.Text = reader.GetString(5).ToUpper();
}
reader.Close();
con.Close();
but it not working
chellappan pandiarajanPosted Jan 16, 2013, 11:17 AM
Try this.....
-Pandian