Print Page | Close Window

Key Press on ReportControl

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Report Control
Forum Description: Topics Related to Codejock Report Control
URL: http://forum.codejock.com/forum_posts.asp?TID=5263
Printed Date: 19 September 2024 at 1:03pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Key Press on ReportControl
Posted By: IDBG
Subject: Key Press on ReportControl
Date Posted: 11 October 2006 at 3:13am
Hi!
 
Is it possible to implement the following:
 
When a user presses a key, say "D", the report control scrolls to the first row that starts with D based on the current sorting.
 
It would be great to be able to implement this.
 
Thanks!
Mir



Replies:
Posted By: sserge
Date Posted: 11 October 2006 at 4:30pm
Well, you'l have to implement this by yourself. Something like below:

Private Sub wndReportControl_KeyDown(KeyCode As Integer, Shift As Integer)

    If KeyCode >= vbKeyA And KeyCode <= vbKeyZ Then
        ' iterate all Rows of the wndReportControl
        '' get Row's Record and iterate all Record Items
        ''' Find whether pressed character does exist in Item's string
        '''' If so, set FocusedRow to currently iterated Row
    End If
End Sub


--
WBR,
Serge


Posted By: IDBG
Date Posted: 14 October 2006 at 5:58am
That worked!! 
 
Thanks!!



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net