how do you generate source code for the automatic generation
for receipt number
Answer / raviarsenal
C # in form load paste this code
try
{
SqlConnection con = new SqlConnection
(@"Data Source=.\sqlexpress;Initial
Catalog=Hospital;Integrated Security=True");
con.Open();
q = "select Billno from PatientBill";
SqlCommand cmd = new SqlCommand(q, con);
SqlDataReader dr = cmd.ExecuteReader();
while (dr.Read())
{
bill = Convert.ToInt32(dr
["Billno"].ToString());
}
txtbillno.Text = (bill + 1).ToString();
dr.Close();
cmd.Dispose();
con.Close();
}
catch (Exception ex)
{
MessageBox.Show(ex.Message);
}
| Is This Answer Correct ? | 0 Yes | 0 No |
through which algorithm does the garbage collector works? how the garbage collector will understand that the object will going to be deleted?
What is the difference between procedure -oriented language and object oriented language?
22 Answers IBM, Infosys, TCS,
What is the difference between CLEAR & RESET and OPEN & CLOSE OPCOEDS(USING RPG/400).wheare we can use this?can any body tell me in real time senario with example please?
Tell me the jobs for the MCA Fresher in delhi, Noida..
if we want to move all the items that are already added in a combobox into an empty list box or vice-versa then how can it possible in vb or C# ?
What is the Difference between in memory database and physical database
What are the compilers of JAVA and .NET Programming languages?
what is the difference between "types" and "data" in abap.
What is Partial class and its use?
Data structure used to impliment a menu:
smal talk is pure object oriented or not?
how MATLSB software suitable for electrical branch? which tools are useful??