I'm trying to set the properties dynamically.
Basically, I'm trying to create a generic editor for database interfaces.
Usually to set the fields from an existing record I do:
FirstName.Text = dRow["FirstName"].ToString();
LastName.Text = dRow["LastName"].ToString();
//etc . . .
To update a DataRow from them I do:
dRow["FirstName"] = FirstName.Text;
dRow["LastName"] = LastName.Text;
// . . .
The problem is, for every editor those functions have to be rewritten because the fields are different (i.e. Event = , EventDate = , etc...)
So, I'm trying to write it so that I can use the same one, no matter what the FIELDS for the given editor are. I don't have to rewrite the SetText, UpdateRec, etc. procs for each editor.
I hope that makes sense.
Anyway, I think what you've given me here is enough to go on.
Thanks very much for your help, on a SUNDAY AFTERNOON?
Sheesh!! What's wrong with us?!?! hehe