Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
710
UltraCombo - changing focus to other control?
posted

Hi there,

Here is my code

Private Sub UltraCombo_Tracks_Results_1_AfterCloseUp(ByVal sender As Object, ByVal e As System.EventArgs) Handles UltraCombo_Tracks_Results_1.AfterCloseUp

ActualTrack_Results1 = CShort(Me.UltraCombo_Tracks_Results_1.Value) - 1

Me.UltraCombo_Tracks_Results_1.Text = "Track Selected" + " - " + Me.UltraCombo_Tracks_Results_1.Text

Me.Fill_Grid_Results_1(ActualTrack_Results1)

Me.UltraGrid_Results_1.Focus()

End Sub

Point is, the last line does nothing!

I'm surprised since a similar code on a Tool really switches the focus.

Any ideas is appreciated.

Thanks in advance!

 

Parents
No Data
Reply
  • 37774
    posted

    I'm guessing here, but it's possible that the underlying .NET TextBox in the combo is taking focus in this code, so this boils down to a timing issue.  You could use a BeginInvoke to delay the call to focus the grid to see if that helps.

    -Matt

Children