add a value to a cbobox lookup

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Good Day all,

I have a cbobox for client information on a frminvoices. I would like the
user to have the option to add a new client and address from the form to the
lookup table.

Is there an easy way to do this?

Thanks,

Brook
 
Use the DdlClick event of the combo, or place a "New Client" button beside
the combo if you think that's more obvious. Use the OpenForm method to open
the client form.

In the AfterUpdate (or AfterInsert) event of the client form, Requery the
combo on the original form so it gets to hear about the new record:
Forms![Form1]![ClientID].Requery
 
Thank you...

Is there a way that I can just open the table and update the table
directly instead of having to create another form?

Thanks again..

Brook

Allen Browne said:
Use the DdlClick event of the combo, or place a "New Client" button beside
the combo if you think that's more obvious. Use the OpenForm method to open
the client form.

In the AfterUpdate (or AfterInsert) event of the client form, Requery the
combo on the original form so it gets to hear about the new record:
Forms![Form1]![ClientID].Requery

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Brook said:
Good Day all,

I have a cbobox for client information on a frminvoices. I would like the
user to have the option to add a new client and address from the form to
the
lookup table.

Is there an easy way to do this?

Thanks,

Brook
 
You can use OpenTable instead of OpenForm.

Much less flexible though, and you will have to manually refresh the combo.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Brook said:
Thank you...

Is there a way that I can just open the table and update the table
directly instead of having to create another form?

Thanks again..

Brook

Allen Browne said:
Use the DdlClick event of the combo, or place a "New Client" button
beside
the combo if you think that's more obvious. Use the OpenForm method to
open
the client form.

In the AfterUpdate (or AfterInsert) event of the client form, Requery the
combo on the original form so it gets to hear about the new record:
Forms![Form1]![ClientID].Requery

Brook said:
Good Day all,

I have a cbobox for client information on a frminvoices. I would like
the
user to have the option to add a new client and address from the form
to
the
lookup table.

Is there an easy way to do this?

Thanks,

Brook
 
I don't see the option for OpenTable when I set up a command button? and when
you say manually refresh the combo box, what do you mean?

Thanks,

Brook

Allen Browne said:
You can use OpenTable instead of OpenForm.

Much less flexible though, and you will have to manually refresh the combo.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Brook said:
Thank you...

Is there a way that I can just open the table and update the table
directly instead of having to create another form?

Thanks again..

Brook

Allen Browne said:
Use the DdlClick event of the combo, or place a "New Client" button
beside
the combo if you think that's more obvious. Use the OpenForm method to
open
the client form.

In the AfterUpdate (or AfterInsert) event of the client form, Requery the
combo on the original form so it gets to hear about the new record:
Forms![Form1]![ClientID].Requery

Good Day all,

I have a cbobox for client information on a frminvoices. I would like
the
user to have the option to add a new client and address from the form
to
the
lookup table.

Is there an easy way to do this?

Thanks,

Brook
 
Brook, we are not doing your work here, just giving you enough to find your
way.

From here, you may need to look under help in the VBA window for:
OpenTable
Requery

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Brook said:
I don't see the option for OpenTable when I set up a command button? and
when
you say manually refresh the combo box, what do you mean?

Thanks,

Brook

Allen Browne said:
You can use OpenTable instead of OpenForm.

Much less flexible though, and you will have to manually refresh the
combo.

Brook said:
Thank you...

Is there a way that I can just open the table and update the table
directly instead of having to create another form?

Thanks again..

Brook

:

Use the DdlClick event of the combo, or place a "New Client" button
beside
the combo if you think that's more obvious. Use the OpenForm method to
open
the client form.

In the AfterUpdate (or AfterInsert) event of the client form, Requery
the
combo on the original form so it gets to hear about the new record:
Forms![Form1]![ClientID].Requery

Good Day all,

I have a cbobox for client information on a frminvoices. I would
like
the
user to have the option to add a new client and address from the
form
to
the
lookup table.

Is there an easy way to do this?

Thanks,

Brook
 
Allen...

I want to thank you for your help... but if your going to slam me for
asking more qeuestions then I would appreciate you not responding, b/c its a
real disapointment!!

I will find my answers elsewhere...


Brook

Allen Browne said:
Brook, we are not doing your work here, just giving you enough to find your
way.

From here, you may need to look under help in the VBA window for:
OpenTable
Requery

--
Allen Browne - Microsoft MVP. Perth, Western Australia.

Reply to group, rather than allenbrowne at mvps dot org.

Brook said:
I don't see the option for OpenTable when I set up a command button? and
when
you say manually refresh the combo box, what do you mean?

Thanks,

Brook

Allen Browne said:
You can use OpenTable instead of OpenForm.

Much less flexible though, and you will have to manually refresh the
combo.

Thank you...

Is there a way that I can just open the table and update the table
directly instead of having to create another form?

Thanks again..

Brook

:

Use the DdlClick event of the combo, or place a "New Client" button
beside
the combo if you think that's more obvious. Use the OpenForm method to
open
the client form.

In the AfterUpdate (or AfterInsert) event of the client form, Requery
the
combo on the original form so it gets to hear about the new record:
Forms![Form1]![ClientID].Requery

Good Day all,

I have a cbobox for client information on a frminvoices. I would
like
the
user to have the option to add a new client and address from the
form
to
the
lookup table.

Is there an easy way to do this?

Thanks,

Brook
 
Back
Top