Update unbound text box on form load and/or next record (1 Viewer)

Morphies

New member
Local time
Today, 12:53
Joined
Dec 8, 2021
Messages
6
Good morning all,

Appreciate the help! I have had a quick search but couldn't find this one. I'm sure it'll have been answered before though.

Issue: Unbound text box does not display data when form loads and does not update when switching between records on the form.

Form Name: Frm_ExposureMaster
Form Type: Single Form
Bound Combobox: cmbPipeSize
Unbound text box: TxtPipeDetails

TxtPipedetails is set to show columns 1 through 5 of cmbPipeSize, so the event procedure on cmbPipeSize is set to:

Code:
Private Sub CmbPipeSize_AfterUpdate()

    TxtPipeDetails = CmbPipeSize.Column(1) & Space(20) & CmbPipeSize.Column(2) & Space(20) & CmbPipeSize.Column(3) & Space(20) & CmbPipeSize.Column(4) & Space(20) & CmbPipeSize.Column(5)
    
End Sub

Thanks,

Morphies.
 

Gasman

Enthusiastic Amateur
Local time
Today, 12:53
Joined
Sep 21, 2011
Messages
10,296
Use the current event of the form.
Plus are you sure?, that is a lot of space characters? :(
 

Morphies

New member
Local time
Today, 12:53
Joined
Dec 8, 2021
Messages
6
Thanks, that'll work.

And yeah it's just for formatting as I have labels above the text box.
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 07:53
Joined
Feb 19, 2002
Messages
35,834
Looks like a poor table design. You seem to have a repeating group.
 

Users who are viewing this thread

Top Bottom