• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 357
  • Last Modified:

Blanks with 2 Combo Boxes Linked On A Contiuous Form

Hi EE,
I have a continuous subform that contains two combo boxes (cb) per record.  The first (cb) refers to an AcctID and the second (cb) to a SubAcctID, each bound by an ID, but displaying a description.  When the User selects an AcctID with the first (cb), the second will be filtered with only the SubAcctID's that have the selected AcctID. That part works fine. I am using the query criteria "[Forms]![frmMain]![frmSub].[Form]![AcctID]" to filter the SubAcctID (cb).  

The problem I am having is when a User goes to a new record the SubAcctID (cb) on the prior records goes blank if a different AcctID is selected, but not if the same AcctID is selected.  The ID's are still attached to the record, but the (cb) is displaying a blank.  I tried a requery,

Private Sub AcctID_AfterUpdate()
Me.SubAcctID.Requery

but it did not help. Any ideas where I am going wrong?
 
Thank you for your time,
Steve
0
SteveStew4444
Asked:
SteveStew4444
  • 2
1 Solution
 
GRayLCommented:
Change:

Me.SubAcctID.Requery

to:

Me.Form.sfmName.Requery

sfmName being the actual name of your subform control.  If Requery does not work, try Refresh.
0
 
SteveStew4444Author Commented:
Did not apply totally
0
 
SteveStew4444Author Commented:
Hi GRayL,
Thanks for the reply.
I believe since "Private Sub AcctID_AfterUpdate()" is in the subform with the other control, i don't need to refer to the parent.
By the way, I fixed the issue by finding an article with a really cool trick that made it work like a charm.
Here's the link:  http://www.vb123.com/kb/index.html?200602_ds_control.htm
Thank you anyway!
Steve
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now