private View.OnClickListener SubmitListener = new OnClickListener() { @Override public void onClick(View v) { // TODO Auto-generated method stub eid = edt_checkout_id.getText().toString(); ename = edt_checkout_name.getText().toString(); Calendar cal = Calendar.getInstance(); SimpleDateFormat dateformat = new SimpleDateFormat( "dd/MM/yyyy_HH:mm:ss.000"); FormattedDate = dateformat.format(cal.getTime()); Log.v("TAG", "FormattedDate=" + FormattedDate); SQLiteDatabase db = db_activity.getWritableDatabase(); ContentValues contentValues = new ContentValues(); contentValues.put(Db_Activity.ID, eid); contentValues.put(Db_Activity.Name, ename); contentValues.put(Db_Activity.CheckOut_Time, FormattedDate); long inserted = db.insert(Db_Activity.Table, null, contentValues); db.close(); db_activity.close(); edt_checkout_id.setText(""); edt_checkout_name.setText(""); Intent intent1 = new Intent(CheckoutActivity.this,Employee_ProjectActivity.class); startActivity(intent1); Toast.makeText(getBaseContext(), "You have been successfully checked out...", Toast.LENGTH_SHORT).show(); } };
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)