POS Software Development

jermaine clarke

Registered User.
Local time
Today, 14:37
Joined
Jun 16, 2007
Messages
16
I would like to use an unbound textbox in a main form to look up values in a combo box located in the subform and keep adding these values as records in the subform.

Jermaine
 
use unbound text box to update values of combo box in subform & add values as records

I would like to use an unbound textbox in a main form to look up values in a combo box located in the subform and keep adding these values as records in the subform.

Jermaine
 
What do you mean by "...look up values in a combo box located in the subform..."? Doesn't the ComboBox work correctly in the SubForm? Is it bound to a field?
 
I would like to use an unbound textbox in a main form to look up values in a combo box located in the subform and keep adding these values as records in the subform.

Jermaine

Can you put that into practical terms? What, exactly are you trying to do (give an example of the data and why you need to do this as it really doesn't make sense to me at the moment).
 
And don't post questions multiple times. I'm going to merge the two posts.
 
Yes. The combo box works perfectly but my goal is to not use the combo box because I would not want users to focus on the table rather, the unbound text box
 
When I say "look up the values", I mean that I want the text box to find records stored in the combo box and then keep adding these records in the combo box as records in the table (subform).
 
Sorry, but that makes no sense at all. Give a specific example (I mean with data described) as to what you are trying to accomplish. A combo box is meant to aid the user so they don't have to type something exactly. A text box can have all sorts of spellings, etc. Why would you have someone type something in that can be selected from a combo box?
 
Bob, since the OP does not appear to be online, I'll throw in my interpretation of the goal. Since they said POS, I'm assuming it's like an invoice, and the subform would contain the line items. I further assume that rather than have the user in the subform, they want them to select "Widget" and have a line item added for Widgets, then select "Thingy" and have a second line item added for Thingy, etc.

jermaine clarke, if that's all true, it's doable, but you'd face the problem of having to go into the subform to play with quantity, price, etc anyway, so I'm not sure it's a net gain. If I've misinterpreted the goal, tell me to shut up and go away. :p
 
Bob, since the OP does not appear to be online, I'll throw in my interpretation of the goal. Since they said POS, I'm assuming it's like an invoice, and the subform would contain the line items. I further assume that rather than have the user in the subform, they want them to select "Widget" and have a line item added for Widgets, then select "Thingy" and have a second line item added for Thingy, etc.

jermaine clarke, if that's all true, it's doable, but you'd face the problem of having to go into the subform to play with quantity, price, etc anyway, so I'm not sure it's a net gain. If I've misinterpreted the goal, tell me to shut up and go away. :p

If that's true, it wouldn't make sense to have the combo on the subform, but on the mainform and a textbox on the subform (much like my POS db you and RG helped me with few months ago).
 
maybe I'm going about it the wrong way but I have been studying other databases and I see where there is only one area where values are typed (correct or not) and then that value is logged in another area (assuming it's a subform) based on a user prompt. Basically, I do not want a user to be adding records in a tabular format. Instead, I would like a simple textbox to be used:

Currently, the combo box in the subform is linked to the products table and retreives a product number. When a user has selected a product number, other information such as price, UOM, taxable or non-taxable attributes and a description are updated in the necessary fields in the subform.
 
pbaldy, u sound just about right. In terms of the quantity and other properties of the product, I could probably use a another form as I have with cashing out, which works very well.
 
pbaldy, I would not want my users to be tampering with any of the data that has to be set by an admin user. All I want the users to focus on is punching in digits that make up a code and then put in a qty. That's all. I have gotten some codes that has allowed automatic updates to my subform for price, UOM, desc, and more.
 
I don't need PM's to get me to reply to a thread. I didn't reply last night because my wife and I went out for our anniversary. You can understand that took priority?

I agree with Bob that this would be a place for a combo rather than a textbox, but in any case, in the appropriate event (the after-update of a combo for instance):

1) pop up an input box to get the quantity
2) use that plus the value of the combo and any other required values to either execute an append query or use the AddNew method of a recordset to add a record to the underlying data of the subform
3) requery the subform to display that record
 
Slight off beat on this - i am fast approaching something similar to this

what i am going to need is for a combo box to look up a valuye and add this to a memo field - what this is is standard sets of words - now the usual append does not work -as it chops off at 255 char - some of my wordings are much longer than that - any ideas
i know its to do with dlook up - but after this i get a bit vague ..g
 
I've tried the recordset approach but it has not worked. Let me try a simpler approach to the question:
I would like to use a combo box in my main form to add records in my subform.
 
I feel like I gave you the basic steps in my last post, so perhaps it would be simplest if you posted the code you've tried that isn't working. Then we can fix that.
 
sub ItemID_AfterUpdate() 'combo box in main form
Dim rst As DAO.Recordset
Dim strSearchName As String
Dim ItemID As String

Set rst=me.Recordset

ItemID=me.ItemID.Text
strSearchName=Cstr(me![Invoice_Subform].Form![ProductID]) 'control in subform
rst.FindFirst "ItemID=" & strSearchName

If rst.NoMath Then
MsgBox "Record not found for " & ItemID & ". Please contact system administrator or Data entry personnel!",vbCritical,"Data not Found:" & ItemID & " !"

End If
End Sub
 
I finally got it to work by setting the property of the value in the textbox. I would like some further help though with the run-time error 2237. I would like to use my own error message in place of the standard message which states that an item is not in the list. Please help me.

Regards,
Jermaine
 

Users who are viewing this thread

Back
Top Bottom