Continuous Form - Populate unbounded field

C

cp2599

All records are populated rather than just the selected record.
I have a continuous form with a combo box that populates a hidden
field. I've added an unbounded text box to display the name
associated to the hidden field. However, although the value in the
hidden field and combo box only appears on the selected record, the
unbounded textbox gets populated on all records rather than just the
one with the value. Here's the code ... was added in the After Update
on the combo box. Please help me contain the dlookup value to the
selected record. Thank you.

If Nz(Me.cboProxyName, 0) = 0 Then
Me.txtProxyName = Null
Me.lngzProxyNameID = Null
Else
If Me.lngzProxyNameID > 0 Then
Me.txtProxyName = DLookup ....
End If
End If
 
C

cp2599

All records are populated rather than just the selected record.
I have a continuous form with a combo box that populates a hidden
field.  I've added an unbounded text box to display the name
associated to the hidden field.  However, although the value in the
hidden field and combo box only appears on the selected record, the
unbounded textbox gets populated on all records rather than just the
one with the value.  Here's the code ... was added in the After Update
on the combo box.  Please help me contain the dlookup value to the
selected record.  Thank you.

    If Nz(Me.cboProxyName, 0) = 0 Then
        Me.txtProxyName = Null
        Me.lngzProxyNameID = Null
    Else
        If Me.lngzProxyNameID > 0 Then
            Me.txtProxyName = DLookup ....
        End If
    End If

Two things ... I found a previous post that hinted unbounded fields
and continuous forms don't mix since there is no place to store that
data - suggestion was to add a dummy field. I also discovered that I
don't need the extra field ... the name displaying in the dropdown
will automatically appear based on the hidden value that was saved.

Sorry for posting too soon.
 

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