Hi everyone
Here's a dilemma I've been having:
I have a public VBA automation module that holds information in a bunch of temporary variables that I want to import into a master data entry form. It doesn't use recordsets directly manipulating tables because I want the user to be able to see the information on the form and check its accuracy, add things and notes, and undo it before its added to the records if its off.
Here's the thing. It works when adding data to the fields that are controls directly on the data entry form
ex
forms!frmDataEntry![control] = CorrespondingVbaTempVariable
This works great. I can click the undo button if for whatever reason the module messed up, and it clears it
But, frmDataEntry also has a many-many subform, sfrmKeywordsMM, that has a list of all corresponding keywords to search it by.
All sfrm Keywords is is the master form to another subform, sfrmKeywords, which only has a single combo box to input a list of keywords.
All these forms and tables work, that is not the problem. The user inputs as many keywords as they like, if it's already been entered, it autolinks it to the existing keyword, and if it hasn't been entered, the user is prompted if they want to add the keyword and it's added to both the keywords table and the MM table.
The problem is, the VBA module I have has an array called strKeywords() thats set to import a list of keywords into this subform, and i can't for the life of me get it to enter even one.
I've tried the sujested subform notation with just one:
forms!frmdataentry!sfrmKeywordsMM.form![cboKeyword] = "test"
just to test it out and it won't enter anything!
Tried: forms!frmdataentry!sfrmKeywordsMM.form!sfrmKeywords.form![cbokeyword] = strKeyword(0) or "test"
and nothing.
I can get it to set the focus to the combobox [cboKeywords] by:
forms!frmDataEntry!sfrmKeywordsMM.setfocus
but i cannot get anything in that combobox for the life of me. And when it finally does, I have no idea how to loop through that array and put each keyword into the next record (as soon as the user enters a keyword and presses tab, it autocreates the next keyword). I've ever tried that with
for i = 1 to n
forms!frmdataentry!sfrmKeywordsMM.form!sfrmKeywords.form!{cboKeyword] = strkeywords & chr(9)
next
with chr(9) returning a string for the tab key. And this obviously does nothing since I can't even get anything in that combobox to start. Help a brotha out?? Thanks!
CN
Here's a dilemma I've been having:
I have a public VBA automation module that holds information in a bunch of temporary variables that I want to import into a master data entry form. It doesn't use recordsets directly manipulating tables because I want the user to be able to see the information on the form and check its accuracy, add things and notes, and undo it before its added to the records if its off.
Here's the thing. It works when adding data to the fields that are controls directly on the data entry form
ex
forms!frmDataEntry![control] = CorrespondingVbaTempVariable
This works great. I can click the undo button if for whatever reason the module messed up, and it clears it
But, frmDataEntry also has a many-many subform, sfrmKeywordsMM, that has a list of all corresponding keywords to search it by.
All sfrm Keywords is is the master form to another subform, sfrmKeywords, which only has a single combo box to input a list of keywords.
All these forms and tables work, that is not the problem. The user inputs as many keywords as they like, if it's already been entered, it autolinks it to the existing keyword, and if it hasn't been entered, the user is prompted if they want to add the keyword and it's added to both the keywords table and the MM table.
The problem is, the VBA module I have has an array called strKeywords() thats set to import a list of keywords into this subform, and i can't for the life of me get it to enter even one.
I've tried the sujested subform notation with just one:
forms!frmdataentry!sfrmKeywordsMM.form![cboKeyword] = "test"
just to test it out and it won't enter anything!
Tried: forms!frmdataentry!sfrmKeywordsMM.form!sfrmKeywords.form![cbokeyword] = strKeyword(0) or "test"
and nothing.
I can get it to set the focus to the combobox [cboKeywords] by:
forms!frmDataEntry!sfrmKeywordsMM.setfocus
but i cannot get anything in that combobox for the life of me. And when it finally does, I have no idea how to loop through that array and put each keyword into the next record (as soon as the user enters a keyword and presses tab, it autocreates the next keyword). I've ever tried that with
for i = 1 to n
forms!frmdataentry!sfrmKeywordsMM.form!sfrmKeywords.form!{cboKeyword] = strkeywords & chr(9)
next
with chr(9) returning a string for the tab key. And this obviously does nothing since I can't even get anything in that combobox to start. Help a brotha out?? Thanks!
CN