adding data to a table via form

T

tonkaplayer

I have a command button that open a form that will allow user to add a new
make and/or model of car. Adding a model requires typing in the new model
name and then selecting the apporpriate make to tie it two. This works well.
My question is if I need to add a new make of car then model my new make
does not show unless I close and reopen the forms. The make of car is keep
in table called (creatively) make. The model is stored in table model. I
guess I am asking is there a refresh/forced update I can put in say the after
update property?
 
M

Maurice

Your form is set to [data entry] if you set this property to [no] you will
see the data you just entered in the form.

- in form design - properties of the form - data entry =no

hth
 
T

tonkaplayer

I think I asked my question wrong. I have a button tha topens the add a new
make of car. I do so add the car close the form. I then open the form add a
new model which requires me to select a make once I enter the mode. Process
goes User enters: Ford in the make form, this adds ford to the Make table.
Then user opens add a model users type say Ranger then slects the make to tie
it to; ford in this case. Trouble ford does not show unless I close all
forms then reopen. I checked what you said and they are set to no. I think I
asked th wrong question. I hope this helps. thanks for replying so quickly.

Maurice said:
Your form is set to [data entry] if you set this property to [no] you will
see the data you just entered in the form.

- in form design - properties of the form - data entry =no

hth
--
Maurice Ausum


tonkaplayer said:
I have a command button that open a form that will allow user to add a new
make and/or model of car. Adding a model requires typing in the new model
name and then selecting the apporpriate make to tie it two. This works well.
My question is if I need to add a new make of car then model my new make
does not show unless I close and reopen the forms. The make of car is keep
in table called (creatively) make. The model is stored in table model. I
guess I am asking is there a refresh/forced update I can put in say the after
update property?
 
M

Maurice

Sorry about that i did not understand it correct. We are talking about
comboboxes that need updating after you have added the various options.

In that case you need to requery the combobox control after the data is
entered in the form. This can be done in the afterupdate event of the textbox
where you add the 'make'.

In the after_update event write: me.combobox.requery

Where the name of the combobox should be replaced by the actual name of your
combobox.

Hope this is clear enough this way otherwise let us know.
--
Maurice Ausum


tonkaplayer said:
I think I asked my question wrong. I have a button tha topens the add a new
make of car. I do so add the car close the form. I then open the form add a
new model which requires me to select a make once I enter the mode. Process
goes User enters: Ford in the make form, this adds ford to the Make table.
Then user opens add a model users type say Ranger then slects the make to tie
it to; ford in this case. Trouble ford does not show unless I close all
forms then reopen. I checked what you said and they are set to no. I think I
asked th wrong question. I hope this helps. thanks for replying so quickly.

Maurice said:
Your form is set to [data entry] if you set this property to [no] you will
see the data you just entered in the form.

- in form design - properties of the form - data entry =no

hth
--
Maurice Ausum


tonkaplayer said:
I have a command button that open a form that will allow user to add a new
make and/or model of car. Adding a model requires typing in the new model
name and then selecting the apporpriate make to tie it two. This works well.
My question is if I need to add a new make of car then model my new make
does not show unless I close and reopen the forms. The make of car is keep
in table called (creatively) make. The model is stored in table model. I
guess I am asking is there a refresh/forced update I can put in say the after
update property?
 
T

tonkaplayer

Thanks that is what I needed. I needed to play with another form but got it
by using your idea on the got focus property. As you can tell I am new to
this. I took a class or two in prgraming manymany years ago. It was top down
design and not module. So what I have learned in thru the tutorials logic
and asking here. This databse is to track students and their parking lot
stickers. They buy them for a year(hopefully could be by semester). Was
planning on one sticker that ahngs from mirro and is trasnferable to a second
or even third car. They may drive which ever cars is running. My users of
course want to search on everything. I created a form with Student
number(unique) last name first name and 3 others. this is based on student
table. A tabform was added in which I put sub forms to handle the form for
the student cars database. So I am getting involved already. I would like to
send you this small database and ask your input. Can I do that here? Now
they say I may not have the movable stickers but stickons style. So multiple
stickers for multiple cars for one student. Makes for a very large single
database or a confusing multiple one at least for me.

Maurice said:
Sorry about that i did not understand it correct. We are talking about
comboboxes that need updating after you have added the various options.

In that case you need to requery the combobox control after the data is
entered in the form. This can be done in the afterupdate event of the textbox
where you add the 'make'.

In the after_update event write: me.combobox.requery

Where the name of the combobox should be replaced by the actual name of your
combobox.

Hope this is clear enough this way otherwise let us know.
--
Maurice Ausum


tonkaplayer said:
I think I asked my question wrong. I have a button tha topens the add a new
make of car. I do so add the car close the form. I then open the form add a
new model which requires me to select a make once I enter the mode. Process
goes User enters: Ford in the make form, this adds ford to the Make table.
Then user opens add a model users type say Ranger then slects the make to tie
it to; ford in this case. Trouble ford does not show unless I close all
forms then reopen. I checked what you said and they are set to no. I think I
asked th wrong question. I hope this helps. thanks for replying so quickly.

Maurice said:
Your form is set to [data entry] if you set this property to [no] you will
see the data you just entered in the form.

- in form design - properties of the form - data entry =no

hth
--
Maurice Ausum


:

I have a command button that open a form that will allow user to add a new
make and/or model of car. Adding a model requires typing in the new model
name and then selecting the apporpriate make to tie it two. This works well.
My question is if I need to add a new make of car then model my new make
does not show unless I close and reopen the forms. The make of car is keep
in table called (creatively) make. The model is stored in table model. I
guess I am asking is there a refresh/forced update I can put in say the after
update property?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top