Ultrawingrid - handling keypress and setting focus to row on enter


Author
Message
Charles R Hankey
Charles R Hankey
StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)StrataFrame VIP (1.3K reputation)
Group: Forum Members
Posts: 524, Visits: 30K


Two Ultrawingrid issues :



What is the best way to cause the focus to go to the first column of the first row when the grid is entered via tabbing from the previous control. i.e. so you can immediately start typing or tabbing through the gird.



How does one handle the keypress so that a ctrl-Tab will exit the grid and move to the next control in the TOController tab order.?



Thanks



( if you know the answer and could email it to me I'd appreciate it as i may need it before the forum goes down for maintenance)



Reply
Ivan George Borges
Ivan George Borges
Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)Strategic Support Team Member (4.9K reputation)
Group: StrataFrame MVPs
Posts: 1.9K, Visits: 21K
Hiya.

This is to Exit and Set Focus to next control. I haven't been able to catch Ctrl+Tab. If you manage it, please let me know:

    Protected Overrides Sub OnKeyDown(ByVal e As System.Windows.Forms.KeyEventArgs)
        If e.KeyCode = Keys.E AndAlso e.Control Then
            SetFocusToNextControl(True)
        End If

        MyBase.OnKeyDown(e)
    End Sub

And this is to enter in Edit mode:

    Protected Overrides Sub OnEnter(ByVal e As System.EventArgs)
        Me.PerformAction(Infragistics.Win.UltraWinGrid.UltraGridAction.ActivateCell)
        Me.PerformAction(Infragistics.Win.UltraWinGrid.UltraGridAction.EnterEditMode)

        MyBase.OnEnter(e)
    End Sub

Hope it helps. Wink

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
Charles R Hankey - 15 Years Ago
Ivan George Borges - 15 Years Ago
Charles R Hankey - 15 Years Ago
Charles R Hankey - 15 Years Ago
Charles R Hankey - 15 Years Ago
Ivan George Borges - 15 Years Ago
Ivan George Borges - 15 Years Ago
Charles R Hankey - 15 Years Ago
Ivan George Borges - 15 Years Ago
Ivan George Borges - 15 Years Ago
                     Clever idea. I'll have a look at it tonight.

Obrigado...
Charles R Hankey - 15 Years Ago
                         Ivan, thank you so much for the groupbox trick to get the...
Charles R Hankey - 15 Years Ago
                             Glad it helped, Charles! ;)
Ivan George Borges - 15 Years Ago

Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search