D
David C. Holley
I have a form in which a user enters a person's name into a comboBox. If
the person's name does not exist in the list, I've got code in the
NotInList event that adds the person's name to the list and then
supresses the error.
*TAKE NOTE*
The names in the comboBox are formated as LastName, First Name (e.g.
'Smith, David')
I have in the NotInList procedure code which detects the existance of a
comma [,] in the newData variable and then processes the newData based
on if the value is LastName/FirstName or FirstName/LastName. (First/Last
is detected by the existance of a space and the lack of a comma.)
*TAKE NOTE*
I am able to successfully create the neccessary records in the
underlying table and have the comboBox requery.
*ACTUAL PROBLEM*
The problem that I have is that if the user enters the name in First
Name/Last Name format [David Smith], the record in the comboBox will
appear as [Smith, David] after its added to the underlying table and the
comobox requeries. How then can I select the new record [Smith, David]?
Using [response = DATA_ERRADDED], Access wants to search for and select
[David Smith] as that is the original value entered.
the person's name does not exist in the list, I've got code in the
NotInList event that adds the person's name to the list and then
supresses the error.
*TAKE NOTE*
The names in the comboBox are formated as LastName, First Name (e.g.
'Smith, David')
I have in the NotInList procedure code which detects the existance of a
comma [,] in the newData variable and then processes the newData based
on if the value is LastName/FirstName or FirstName/LastName. (First/Last
is detected by the existance of a space and the lack of a comma.)
*TAKE NOTE*
I am able to successfully create the neccessary records in the
underlying table and have the comboBox requery.
*ACTUAL PROBLEM*
The problem that I have is that if the user enters the name in First
Name/Last Name format [David Smith], the record in the comboBox will
appear as [Smith, David] after its added to the underlying table and the
comobox requeries. How then can I select the new record [Smith, David]?
Using [response = DATA_ERRADDED], Access wants to search for and select
[David Smith] as that is the original value entered.