We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Automated testing of grid controls

Thread ID:

Created:

Updated:

Platform:

Replies:

21678 Nov 17,2004 12:15 PM UTC Nov 17,2004 04:54 PM UTC WinForms 2
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On November 17, 2004 12:15 PM UTC

I''m trying to automate testing of our derived grid control using NUnit and NUnit Forms. One issue I have is that when I try to do a test that involves keyboard input, it''s failing because it''s trying to set focus to the grid as a whole instead of the cell in the grid, as each key is pressed. How can I get the System.Windows.Forms.Control reference of the current cell so that I can have NUnit Forms set the focus there for keyboard input? Pete

Administrator [Syncfusion]
Replied On November 17, 2004 03:10 PM UTC

Not sure it will work for this setup, but you can try: this.grid.CurentCell.BeginEdit(); Or, maybe this.grid.CurrentCell.Renderer.Control.Focus(); You would probably need to check for nulls.

Administrator [Syncfusion]
Replied On November 17, 2004 04:54 PM UTC

Thanks Clay. That will probably do it. Unfortunately, I''ve just discovered that NUnit Forms has no facility for me to pass it a Control object. It''s got a really screwed up architecture and wants a form and control name. Nor does it even store the actual control reference, so there''s no way to simply add a constuctor to pass in the control. Guess I''ve got some work to do. Thanks. >Not sure it will work for this setup, but you can try: > >this.grid.CurentCell.BeginEdit(); > > >Or, maybe > > >this.grid.CurrentCell.Renderer.Control.Focus(); > > >You would probably need to check for nulls.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

;