Advertisement

06.20.2008 at 07:33AM PDT, ID: 23502334
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.2

Access 2003 - Populating a text field from a combo box within a sub form

Asked by jdol2949 in Access Forms, Microsoft Visual Basic.Net, Access Coding/Macros

Tags: , ,

I currently have a main form 'frmBOMtest' that has two combo boxes.  The first filters item classes, and the second box then would show the available parts with the class selected in the first combo box.  That selection is then added to the primary key field of the sub form, so as to tag what SKU goes with the parts that are going to be selected in the subform.
My subform has 5 fields on it.  
ItemSKU (PK, hidden)
DateEntry (PK, hidden)
PartNumber (combo box)
Quantity (control source is selected to 'tblParts')
Price (which is an unbound text box, relating to a separate table called 'Item'.)
When I select the Part Number combo box, I want the Price to automatically look up a value from the 'Item' table that queries the associated price with the item selected in the combo box.  The problem I'm having is that when I use an AfterUpdate command string tied into a listbox (no row source with text boxes?), it finds the associated price, but it updates all fields in the 'Price' column with the value I just picked.  Is there a way where I can just pick the SKU, select a part in the sub form, have the price show next to that part on that row, and then move to the second row and repeat?  (for as many parts as necessary, probably up to 15 for each SKU)

here is the afterupdate snippet I was using in an attempt to populate the 'Price' field on the subform, which I'm sure is wrong, but it gives you an idea of what I'm trying to do:Start Free Trial
1:
2:
3:
Private Sub cboSelectPart_AfterUpdate()
    Me.lbxPrice.RowSource = "select [Item].[Price] from Item where ItemNmbr = '" & Me.cboSelectPart & "'"
End Sub
[+][-]06.20.2008 at 08:10AM PDT, ID: 21831957

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Access Forms, Microsoft Visual Basic.Net, Access Coding/Macros
Tags: Microsoft, Access, 2003
Sign Up Now!
Solution Provided By: peter57r
Participating Experts: 2
Solution Grade: B
 
 
[+][-]06.20.2008 at 08:15AM PDT, ID: 21832010

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]06.20.2008 at 08:20AM PDT, ID: 21832067

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]06.20.2008 at 08:28AM PDT, ID: 21832134

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]06.20.2008 at 08:56AM PDT, ID: 21832398

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]06.20.2008 at 09:12AM PDT, ID: 21832563

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]06.20.2008 at 09:16AM PDT, ID: 21832610

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]06.20.2008 at 09:19AM PDT, ID: 21832629

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]06.20.2008 at 09:44AM PDT, ID: 21832884

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628