John Sh's latest activity

  • J
    John Sh replied to the thread When "X" is not equal to "X".
    I stand corrected on that point, however <You can set focus on any control as long as it's not disabled.> and visible
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    If a control has focus and you try to setfocus to that control you will get an error. Majp insists on leaving out the "if activecontrol...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    I've changed the code to the following and it now works correctly, even with the same value in each combo. You certainly put me on the...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    Actually it only appears to work. It returns the contents of the control, not the name. So if I put 1 in each combo there is no change...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    Thank you. That does exactly what I want, although I did get trapped where there was no active control. I can't use it in a load event...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    Au contraire. You have left out the comparison. Your code actually does nothing. The code, below from arnelgp mirrors my code but passes...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    what I wrote is this, Private Sub isInFocus(str As String) If Me.ActiveControl.Name = str Then Exit Sub...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    Do you think there is a difference between the active control and the control with focus? Of course not, they are one and the same. What...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    Read what you have just written, you have proven yourself wrong. <<<if cboSpecies does not have focus it now has focus>>> or "if...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    That is your interpretation. It is not what I have written. In plain English. If the input to the sub, str, is the same as the name of...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    Read the code. there is no "Else" clause involved. Private Sub isInFocus(str As String) If Me.ActiveControl.Name <> str Then...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    Sounds good but the rowsource for the controls has to be changed to correct for the different inputs. Private Sub btnBot_Click()...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    That's precisely what it's supposed to do. If the active control is the same as the control having setfocus applied then nothing...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    It's highlighted because I was stepping through to get the screen shots. I have tried the long version, same result but I haven't tried...
  • J
    John Sh replied to the thread When "X" is not equal to "X".
    In the case that a query only returns one result, the combobox waits to be updated, In this case I call combo_afterupdate which has the...
    • Screenshot_58.jpg
Top Bottom