AllExperts > Using MS Access 
Search      
Using MS Access
Volunteer
Answers to thousands of questions
 Home · More Using MS Access Questions · Answer Library  · Encyclopedia ·
More Using MS Access Answers
Question Library

Ask a question about Using MS Access
Volunteer
Experts of the Month
Expert Login

Awards

About Us
Tell friends
Link to Us
Disclaimer

 
 
 
 
About Scottgem
Expertise
I can answer almost all types of questions relating to Microsoft Access usage and application design. My strengths are database and interface design.

Experience
I've been designing databases for over 15 years working with dBase, FoxPro, Approach and Access.

Organizations
Author of Microsoft Office Access 2007 VBA
Techncial Editor for Special Edition Using Microsoft Access 2007 and Access 2007 Forms, Reports & Queries From Que Publishing

 
   

You are here:  Experts > Computing/Technology > Business Software > Using MS Access > Form / Combo box issues

Using MS Access - Form / Combo box issues


Expert: Scottgem - 7/10/2009

Question
So I think i'm getting closer, but still having some problems with my form. Perhaps it is best to explain what I am trying to accomplish first. Instead of using the record navigation button, I want to create a combo box that allows the user to select an item, then displays records related to that item and allows the user to add a new entry to the item.

I am binding my form a query because I have a calculated field.

So what I've done is I've moved my combo box to the form header. Then I have my fields below in the detail section. The query contains a WHERE statement set to equal the value of the value of the combo box. I have set the form to ContinuousForms.

My issues are the following:

1) When you change values in the combo box the detail section does not update accordingly. To get it to update I had to add a Form.Requery statement to Combobox_AfterUpdate.  Is there another way to do this?

2) After I've added that code my detail section now it sort of works except that it creates a new entry automatically which has the all values blanked out. How do I stop this from happening? It shows the blank record followed by the query result and then a * new record below. I just want the * new record.

I am sure there must be a simpler way to accomplish what I'm trying to do, but I can't for the life of me get it to work!

Thanks!  

Answer
1) No, that is the way to do it.

2) If its showing a blank record, then your query is returning a blank record. Open the query to check this out. Then change the query so it doesn't show blank records.

Hope this helps,
Scott<>
Microsoft Access MVP 2007
Author: Microsoft Office Access 2007 VBA

Add to this Answer   Ask a Question


 
User Agreement | Privacy Policy | Kids' Privacy Policy | Help
Copyright  © 2008 About, Inc. AllExperts, AllExperts.com, and About.com are registered trademarks of About, Inc. All rights reserved.