Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2003
    Posts
    311

    Unanswered: selection change event of CBO

    I have a cboCo and a text box txtCk

    I would like to append - & the selection of cboCo to the data in txtck

    how too?
    <M>~

  2. #2
    Join Date
    Feb 2004
    Posts
    142
    In the afterupdate event

    if not isnull(me!cboCo) then
    me!txtCk = me!txtCk & ", " & me!cboCo
    endif

    This appends the comboboxes contents to textbox with a comma if there was a selection made. It will run as many times as the user makes selections.
    KC

  3. #3
    Join Date
    Oct 2003
    Posts
    311
    Originally posted by AZ KC
    In the afterupdate event

    if not isnull(me!cboCo) then
    me!txtCk = me!txtCk & ", " & me!cboCo
    endif

    This appends the comboboxes contents to textbox with a comma if there was a selection made. It will run as many times as the user makes selections.
    Ok,, alls well, but....

    If the person entered a value by accident and then wants to change it i handled that,,, but my new value wont show in the Txtbox, only if i go to design view then form view will the correct data show

    If Not IsNull(Me.cboCompany.Value) Then
    If Not InStr(Me.CheckNum.Value, "-") > 0 Then
    Me.CheckNum = Me.CheckNum & "-" & Me.cboCompany.Value
    Else
    Me.CheckNum = Left(Me.CheckNum, InStr(Me.CheckNum.Value, "-") - 1) & "-" & Me.cboCompany.Value
    End If
    End If

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •