Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 73: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 74: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 75: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 76: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 77: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /bbc_download.php on line 78: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
package com.example; import java.io.IOException; import java.net.MalformedURLException; import java.net.URL; import java.util.Date; import javax.xml.parsers.ParserConfigurationException; import javax.xml.parsers.SAXParser; import javax.xml.parsers.SAXParserFactory; import org.xml.sax.InputSource; import org.xml.sax.SAXException; import org.xml.sax.XMLReader; import android.app.Activity; import android.app.AlertDialog; import android.content.Intent; import android.os.Bundle; import android.view.Display; import android.view.View; import android.view.View.OnClickListener; import android.widget.AdapterView; import android.widget.ArrayAdapter; import android.widget.ImageButton; import android.widget.LinearLayout; import android.widget.ListView; import android.widget.TextView; import android.widget.AdapterView.OnItemClickListener; public class GetItDoneCalender extends Activity { TextView datetxt; AlertDialog alrt; String currentDate; ListView timetasklist; LinearLayout ll; private int month; private int year; private int date; private String myList[]; ImageButton nextDate; ImageButton previousDate; private String totalDate; Date dt; private AlertDialog show; private GetItDoneCalender local; CalenderDataParsed cdp; Display getOrient; public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.calender); local = this; datetxt = (TextView) findViewById(R.id.datetxt); timetasklist = (ListView) findViewById(R.id.timetasklist); nextDate = (ImageButton) findViewById(R.id.nextCalButton); previousDate = (ImageButton) findViewById(R.id.prevCalButton); ll = (LinearLayout) findViewById(R.id.lineartasklayout); dt = new Date(); date = dt.getDate(); month = 1 + dt.getMonth(); year = 1900 + dt.getYear(); totalDate = date + "-" + month + "-" + year; datetxt.setText(totalDate); passTheDate(totalDate); nextDate.setOnClickListener(new OnClickListener() { public void onClick(View args0) { if (month == 1 || month == 3 || month == 5 || month == 7 || month == 8 || month == 10 || month == 12) { if (date < 31) { date++; } else { date = 1; if (month < 12) { month++; } else { month = 1; year++; } } } else if (month == 4 || month == 6 || month == 9 || month == 11) { if (date < 30) { date = date + 1; } else { date = 1; if (month < 12) { month++; } else { month = 1; year++; } } } else { if (year % 4 == 0) { if (date < 29) { date++; } else { date = 1; if (month < 12) { month++; } else { month = 1; year++; } } } else { if (date < 28) { date++; } else { date = 1; if (month < 12) { month++; } else { month = 1; year++; } } } } totalDate = date + "-" + month + "-" + year; datetxt.setText(totalDate); passTheDate(totalDate); } }); previousDate.setOnClickListener(new OnClickListener() { public void onClick(View args0) { if (month == 2 || month == 4 || month == 6 || month == 9 || month == 11 || month == 1) { if (date > 1) { date--; } else { date = 31; if (month > 1) { month--; } else { month = 12; year--; } } } else if (month == 5 || month == 7 || month == 8 || month == 10 || month == 12) { if (date > 1) { date--; } else { date = 30; if (month > 1) { month--; } else { month = 12; year--; } } } else { if ((year - 1) % 4 != 0) { if (date > 1) { date--; } else { date = 28; if (month > 1) { month--; } else { month = 12; year--; } } } else { if (date > 1) { date--; } else { date = 29; if (month > 1) { month--; } else { month = 12; year--; } } } } totalDate = date + "-" + month + "-" + year; datetxt.setText(totalDate); passTheDate(totalDate); } }); } public void passTheDate(String myDate) { currentDate = myDate; URL url = null; try { url = new URL( "C:/Documents and Settings/ayush/Desktop/GetItDone Dummy/working.xml"); // url = new // URL("http://www.anddev.org/images/tut/basic/parsingxml/example.xml"); } catch (MalformedURLException e1) { show = new AlertDialog.Builder(local).setTitle("welcome") .setMessage(e1.getMessage()).show(); } SAXParserFactory spf = SAXParserFactory.newInstance(); SAXParser sp = null; XMLReader xr = null; try { sp = spf.newSAXParser(); } catch (ParserConfigurationException e) { show = new AlertDialog.Builder(local).setTitle("welcome") .setMessage(e.getMessage()).show(); } catch (SAXException e) { show = new AlertDialog.Builder(local).setTitle("welcome") .setMessage(e.getMessage()).show(); } try { xr = sp.getXMLReader(); } catch (SAXException e) { show = new AlertDialog.Builder(local).setTitle("welcome") .setMessage(e.getMessage()).show(); } CalenderHandler calhldr = new CalenderHandler(); // ExerciseHandler calhldr=new ExerciseHandler(); xr.setContentHandler(calhldr); try { xr.parse(new InputSource(url.openStream())); } catch (IOException e) { // show=new // AlertDialog.Builder(local).setTitle("welcome").setMessage(e.getMessage()).show(); } catch (SAXException e) { show = new AlertDialog.Builder(local).setTitle("welcome") .setMessage(e.getMessage()).show(); } /*CalenderDataParsed*/ cdp = calhldr.getParsedData(); // ParsedData cdp= calhldr.getParsedData(); int workCount; workCount = cdp.totalWorkCount(); myList = new String[workCount]; String str = null; for (int i = 0; i < myList.length; i++) { try { getOrient = getWindowManager().getDefaultDisplay(); if(getOrient.getWidth() <= getOrient.getHeight()) { if(cdp.toString().length()<35) { myList[i] = cdp.toString(); } else { myList[i]=cdp.toString().substring(0, 35)+"..."; } } else { if(cdp.toString().length()<52) { myList[i] = cdp.toString(); } else { myList[i]=cdp.toString().substring(0, 52)+"..."; } } } catch (Exception e) { show = new AlertDialog.Builder(local).setTitle("welcome") .setMessage("hello " + e.getMessage()).show(); } } // String[] myList = new String[] // {"Hello","Sapple","System","we ","gonna","take","over","apple","cmpny"}; timetasklist = new ListView(this); timetasklist.setAdapter(new ArrayAdapter(this, android.R.layout.simple_list_item_1,myList)); ll.addView(timetasklist); timetasklist.setOnItemClickListener(new OnItemClickListener() { public void onItemClick(AdapterView adapterView, View view, int position, long id) { // SimpleAdapter adapter = (SimpleAdapter) // adapterView.getAdapter(); // show = new AlertDialog.Builder(local).setTitle("welcome") // .setMessage("you have clicked on " + currentDate+"at the position "+position).show(); Intent myIntent = new Intent(view.getContext(), JobOption.class); Bundle b=new Bundle(); b.putString("Date",currentDate); b.putString("Time",cdp.extractedTime); b.putString("Destination",cdp.extractedDescription); b.putInt("TaskID", cdp.extractedTaskId); myIntent.putExtras(b); startActivityForResult(myIntent, 0); } }); } }