how do you generate source code for the automatic generation
for receipt number
Answer Posted / 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 |
Post New Answer View All Answers
Bonjour, svp je veut voir comment envoyer un mail en java et comment changer le droit d'accé d'un fichier en java: de lecture en lecture/écriture et merci d'avance ;)
what is apt_dump_score in datastage where it is useful
1.how to deploy the Maven application in weblogic server? 2.In Real time projects all classes are singleton or some classes only singleton explain? 3.what are the major uses of the designpatterns? 4.explain restful &Soap based services explain?
How do you initialize a static member of a class with return value of some function?
< No Frames > tag is used for
what are the topics choosen for jam round for interviews
Need guidewire related Documents(Interview Question/Tips/Best Practice/Dumps)
Hi guyes, I have cleared 2 technical rounds with cts for liferay and java techonologies, i have client round next week, please tell me how to prepare for this what questions i should be ready to face?
what are all the ant command options
What sysoption determines where the macro facility searches a specific catalog for complied macro?
suppose we have ten members of a physical file but we want the output of last 5 members only.how to achieve that?
Write a program to find whether a given number is prime or not.
can we retrieve only integer/String type columns from a table,if yes how?
Describe the difference between Interface-oriented, Object-oriented and Aspect-oriented programming
Compare any 4 software development life cycle paradigms with each other. Indicate at least one application for each of the paradigms that are suitable to developed using that paradigm.