combo selection help!!

L

LJG

I have a combo box setup that works fine, looks up items and values etc,
however, my bosses have now decided they want 4 price options based on the
qty of items ordered.

Previously I just had a simple [cost]*[qty] which gave me a [linesum]

Now I need to get the combo to change based on the qty of items ordered. Up
to 4 its the same as above, from 5 - 9 I need it to look up the values from
another column, then if it's 10 - 14 get the values from another etc.

Can anyone help me with this?

TIA

Les
 
L

LJG

This is what I am trying....with no luck....any tips ?

Private Sub Form_Current()
If Me.qty < 4 Then
Me.[1 off] = cbosoft.Column(2)
If Me.qty >= 5 < 9 Then
Me.[1 off] = cbosoft.Column(3)
End If
End If
End Sub
 
G

Guest

Create a table for the price levels and link it to your parts table

Your Price Table could look like this

Part_Price_tab(Part_No,Min_Qty,Max_Qty,Price)

make the Primary key Part_No,Min_Qty

to get your price depending on the quantity use dlookup like this if
calculating from the form:

=dlookup("[Price]", _
"Part_Price_tab", _
"[Part_No]='" & me.part_no & "' " & _
"and [Min_Qty] <= " & me.quantity & " " & _
"and [Max_Qty] >= " & me.quantity & "")

with this you can have multiple price levels (not only 4)
--
jl5000
<a href="http://joshdev.com"></a>


LJG said:
This is what I am trying....with no luck....any tips ?

Private Sub Form_Current()
If Me.qty < 4 Then
Me.[1 off] = cbosoft.Column(2)
If Me.qty >= 5 < 9 Then
Me.[1 off] = cbosoft.Column(3)
End If
End If
End Sub


LJG said:
I have a combo box setup that works fine, looks up items and values etc,
however, my bosses have now decided they want 4 price options based on the
qty of items ordered.

Previously I just had a simple [cost]*[qty] which gave me a [linesum]

Now I need to get the combo to change based on the qty of items ordered.
Up to 4 its the same as above, from 5 - 9 I need it to look up the values
from another column, then if it's 10 - 14 get the values from another etc.

Can anyone help me with this?

TIA

Les
 

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