I have an activity that extends ListView. I populate my list with the results of a query to the sqlite database. A list element consists of start_time, end_time, client_name an
You should try to loosen yourself from the web development frame of mind a little bit. There is no need to store such a thing as the id in a hidden field in your view. That would mix your data with your user interface and create a lot of confusion and unnecessary view objects.
If you are using a sqlite database to store your values you should use a CursorAdapter to manager your list items. The CursorAdapter stores the result that you got from the Database and manages how the data is displayed to the user. If you then register an onItemClickListener on your ListView the listener will receive the adapter and the position of the data item whose cell was clicked in the adapter. Now you can use getItem to retrieve a cursor pointing to the database result that was used to create the listitem. Now you can get the id or all other values that are not shown to the user from the database result and attach it to an intent to start the next activity.
If you need non-displaying db cols other than _id, in your ListView's onItemClick(...) you just call:
mAdapter.getCursor();
Then you can get any non-displaying cols of the selected list item/row.
As Janusz mentioned, if you only need _id, just call:
mAdapter.getItemId();
You should consider creating a java object which would gather all this information. for instance, you could create a class like "ListItem" and each item would have 5 properties :
start_time
end_time
client_name
status
id
(and more if you need)
And then, you have 2 options, either you serialize you object to put the whole object in the database, or you keep the structure you already have (I suppose), and each row of your database becomes a ListItem object. Then, when you query your database, you put them all in an ArrayList, and extend ArrayAdapter to make your own adapter. Finally, in the getView method, you call myListItem.getEnd_Time and all the method you need to display your data, and simply don't use the getId, which you can directly use from the adapter when you need the object.