can i update more then one field by entering in 1 combo?

killerwhale65

Registered User.
Local time
Yesterday, 16:28
Joined
Jun 28, 2004
Messages
32
Hi all,

I was wondering if it is possible to update more then i fields in a table by entering a new value in a combobox? Right now when i enter a new value in the combo, it puts that value in the first field. But i would like to update 3 fields (of wich 1 is the combo), because i cannot update them in the form cause they are linked to the combobox.

Anyone knows any help here?

Thanks!

Matt
 
Don't duplicate your data. If you have it stored and presented in a combobox then there's no need to put it into another table.
 
Mile-O-Phile said:
Don't duplicate your data. If you have it stored and presented in a combobox then there's no need to put it into another table.
yes, but i am talking about data that is not stored yet.

so i need to enter a value in the combo, that is not yet in the combolist. And together with that i also have to enter new values in the second and third field.
 
Ah, gotcha!

Look in the FAQ forum for my Adding values to a table. It can be adapted to open a form to add multiple values.
 
Mile-O-Phile said:
Ah, gotcha!

Look in the FAQ forum for my Adding values to a table. It can be adapted to open a form to add multiple values.

I already did that but it doesnt work either. I'm sure it can be adapted, but im not a VBA scriptwriter, so i wouldnt have a clue how to to that...
 
thanks

getting a VB runtime error however when entering a new value ("you cant assign a value to this object")
 
ok, i tried the example u provided and that works fine.
However then i transfered that to my own database, but i do not get it to display the message "... is not in the lest do u wanna add it". I have exactly the same event procedure added to the "not in list" situation of the combo.

What am i doing wrong here?
 
Ok the script u gave me works fine on its own.
But from the moment i select tblExample as a source for frmStart, and i want to add a new value in the combo, it adds it twice to tblExample. Moreover, when i reopen frmStart, the newly added values only show something in the combo, and not in fields txtOther1 and txtOther2.

What am i doin wrong here?

thanks,

Matt
 
Last edited:
Have you set the LimitToList property to Yes?
 
just checked and the limittolist property for the combo in frmStart is set to yes
 
i think it adds one record when i press enter (at that point the messagebox appears that asks if i want to add it), and then a second time when i enter the data in frmExample.

Question1: why does it only do so when i select a recordsourse for frmStart
Question2: how can i get around it so thet only one record is filled please?

thanks!

Matt
 

Users who are viewing this thread

Back
Top Bottom