Hi again,
the further I develop my small helper tool, the more details I need to get along with.


My current problem:
I read the columns from a MDB file and display them in some textboxes in the Form.
Since the MDB file has some few rows, the main entry with the name is displayed in a treeview like this:

MDB:

ID | Name | Info
---------------------
1 | Test | Info1
2| TestA | Info2
3 | TestB | Info3



GUI (treeview):
|---Test
|---TestA
|---TestB


Depending on the treeviews selection I change the content of the textboxes.
I do this so far by retrieving the SelectedNode.Index and look up the MDB for WHERE ID = index.
This works fine.

But I need a way to be independent of the SelectedNode.Index, cause I will implement some
filters so the treeview contains not all available entries and the indexes will be messed up.


How can I figure out the ID (or the row number) depending of a given Name (second column from MDB).

For example: I want the ID from 'TestA'. How can I do this?
I cannot use reader.GetString(0); to get the autonumbered values from "ID". It does not work. The very first valid column I can access is "Name" by reader.GetString(1) :-(

Some hints?