+ Reply to Thread
Results 1 to 4 of 4

RefEdit

  1. #1

    RefEdit

    Can someone suggest a way around this? I use a RefEdit control to
    allow a user to select several columns to be processed. However
    RefEdit1_Change is processed multiple times. i.e. when the user
    activates the RefEdit control on the form, and selects a range, the
    RefEdit1_Change sub is processed more than once. Is there a way of
    processing the range that was selected when the user exits the RefEdit
    control and reverts to the form?

    tia

    bob


    Sub RefEdit1_Change()

    ....some code

    End Sub

  2. #2
    Bob Phillips
    Guest

    Re: RefEdit

    Use the Exit event.

    --
    HTH

    Bob Phillips

    (remove nothere from email address if mailing direct)

    <[email protected]> wrote in message
    news:[email protected]...
    > Can someone suggest a way around this? I use a RefEdit control to
    > allow a user to select several columns to be processed. However
    > RefEdit1_Change is processed multiple times. i.e. when the user
    > activates the RefEdit control on the form, and selects a range, the
    > RefEdit1_Change sub is processed more than once. Is there a way of
    > processing the range that was selected when the user exits the RefEdit
    > control and reverts to the form?
    >
    > tia
    >
    > bob
    >
    >
    > Sub RefEdit1_Change()
    >
    > ...some code
    >
    > End Sub




  3. #3

    Re: RefEdit

    Thanks, I tried it.

    When I use the Exit event, no controls on the form are updated until I
    click on one of the controls. i.e. at the in the Exit event, I load
    the selected columns to a listbox and set the RefEdit1.Text to "".
    When teh Exit event finishs, neither of these things are visible or
    seem to have happened. When I click any other control on the form,
    the ListBox displays the columns as it should and the RefEdit control
    now displays "". Any idea what causes this, or, how I could simulate
    a mouse click on one of the controls?

    Thanks
    bob

    On Sun, 12 Mar 2006 23:04:36 -0000, "Bob Phillips"
    <[email protected]> wrote:

    >Use the Exit event.


  4. #4

    Re: RefEdit

    That was not too clear... sorry

    Here is an example of what I was trying to say...


    Sub RefEdit1_Exit(ByVal Cancel As MSForms.ReturnBoolean)
    MsgBox "fff"
    RefEdit1.Text = ""
    End Sub

    The MsgBox does not come up, and RefEdit.Text is not set to "" until I
    click some other control on the form.

    bob

    On Sun, 12 Mar 2006 17:39:39 -0500, [email protected] wrote:

    >Can someone suggest a way around this? I use a RefEdit control to
    >allow a user to select several columns to be processed. However
    >RefEdit1_Change is processed multiple times. i.e. when the user
    >activates the RefEdit control on the form, and selects a range, the
    >RefEdit1_Change sub is processed more than once. Is there a way of
    >processing the range that was selected when the user exits the RefEdit
    >control and reverts to the form?
    >
    >tia
    >
    >bob
    >
    >
    >Sub RefEdit1_Change()
    >
    >...some code
    >
    >End Sub


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1