SapGridView Class

Description

Class for SAP GridView. Some of the methods that have Get as a prefix require the column as an iput parameter of type string. This parameter is different for each individual GridView element. To obtain the value of this parameter, record an action on the desired item and use the parameter that you have recorded.

Inheritance Hierarchy

Syntax

C#
public class SapGridView : SapShell, ISapContextMenuable
VB
'Declaration
Public Class SapGridView _
Inherits SapShell _
Implements ISapContextMenuable

Properties

Name Description
AccessibilityText an additional text for accessibility support. (Inherited from SapComponent)
AccessibilityTextOnRequest an additional text for accessibility support. (Inherited from SapComponent)
AccessibilityTooltip an additional tooltip text for accessibility support. (Inherited from SapComponent)
Changeable whether an object is changeable. (Inherited from SapComponent)
ColumnCount the number of columns.
ColumnOrder a list of strings which contains all the column identifiers in the order in which they are displayed.
CurrentCellColumn the current column.
CurrentCellRow the current row.
CurrentContextMenu The current context menu. This is only set when a context menu is available at the shell object.
DefaultTooltip the tooltip text which is generated from the short text defined in the data dictionary for the given screen element type. (Inherited from SapComponent)
DragDropSupported whether the shell allows drag and drop operations. (Inherited from SapShell)
FirstVisibleColumn the first visible column of the scrollable area of the grid view, fixed columns are ignored.
FirstVisibleRow the index of the first visible row in the grid.
FrozenColumnCount the number of columns that are excluded from horizontal scrolling.
Height the current height of the component. (Inherited from SapComponent)
IconName whether the object has been assigned an icon, then this property is the name of the icon, otherwise it is an empty string. (Inherited from SapComponent)
IsSymbolFont whether the component's text is visualized in the SAP symbol font. (Inherited from SapComponent)
Left the left position of the element in screen coordinates. (Inherited from SapComponent)
Modified whether the state has been changed by the user and this change has not yet been sent to the SAP system. (Inherited from SapComponent)
Name the name of the component. (Inherited from SapComponent)
RowCount the number of rows.
ScreenLeft the left position of the component in screen coordinates. (Inherited from SapComponent)
ScreenTop the top position of the component in screen coordinates. (Inherited from SapComponent)
SelectedCells a list of strings that contains the selected cells, each of which has the format "<row>,<column id>".
SelectedColumns a list of strings of currently selected columns.
SelectedRows a comma separated list of row index numbers or index ranges, such as "1,4,6-8".
SelectionMode the selection mode. Possible values are: "RowsAndColumns", "ListboxSingle", ListboxMultiple", "Free".
Text The text of the control. (Inherited from TestObject)
Title the title of the grid control.
ToolbarButtonCount the number of tool bar buttons (separators included).
Tooltip the tooltip text. (Inherited from SapComponent)
Top the top coordinate of the element in screen coordinates. (Inherited from SapComponent)
Value The value of the control, e.g.: text in a text control. (Inherited from TestObject)
VisibleRowCount the number of visible rows of the grid view.
Width the current width of the component. (Inherited from SapComponent)

Methods

Name Description
CaptureBitmap Saves a bitmap image of this object to a file. If you do not specify an absolute file name, the bitmap is saved to the default bitmap location on the machine that runs the Agent, which is %LOCALAPPDATA%/Silk/SilkTest/capturedBitmaps. The captured bitmap's pixels are stored in 32bit RGB order; when parsing the image the 4th byte (alpha channel) of every pixel must be ignored as it is used only for padding. In .NET, the constant System.Drawing.Imaging.PixelFormat.Format32bppRgb can be used for this purpose. (Inherited from TestObject)
ClearSelection Removes all row, column and cell selections.
Click Clicks on the specified cell.
ClickCurrentCell Clicks the current cell.
ContextMenu Requests the context menu.
CurrentCellMoved This function notifies the server that another cell was made the current cell. The function must be called whenever the current cell changes.
DeleteRows Delete the given rows.
DeselectColumn Removes the specified column from the list of selected columns.
DoubleClick Double clicks the specified cell.
DoubleClickCurrentCell Double clicks on the current cell.
DuplicateRows Duplicates the given range of rows
Exists Checks if any child object matching the locator exists for an object in the application under test. If the timeout parameter is passed the agent retries finding until the given timeout expires. If no timeout is specified and no object is found initially false is returned immediately. (Inherited from TestObject)
Exists Checks if an object exists in the application under test. (Inherited from TestObject)
Find Finds an object specified by an XPath locator. (Inherited from TestObject)
FindAll Finds all objects specified by an XPath locator. (Inherited from TestObject)
GenerateLocator Returns a locator for this object. (Inherited from TestObject)
GetCellColor Returns an identifier for the color of the cell.
GetCellHeight Gets the height of the cell in pixels.
GetCellIcon Gets the icon string of the specified cell.
GetCellLeft Gets the left position of the cell.
GetCellMaxLength Gets the maximum length of the cell in number of bytes.
GetCellState Gets the state of the specified cell. Possible values are: Normal, Error, Warning, Info.
GetCellTooltip Gets the tooltip of the specified cell.
GetCellTop Gets the top position of the specified cell.
GetCellType Gets the cell type of the specified cell.
GetCellValue Gets the value of the specified cell.
GetCellWidth Gets the width of the specified cell.
GetChildren Returns the child objects of this object. (Inherited from TestObject)
GetColorInfo Returns the description for the color of the cell.
GetColumnDataType Gets the data type of the column.
GetColumnPosition Gets the position of the specified column.
GetColumnSortType Gets the sort type of the column. Possible values are: None, Ascending, Descending.
GetColumnTitles Gets all column titles of the specified column.
GetColumnTooltip Gets the tool tip text of the specified column.
GetColumnTotalType Gets the total type of the column. Possible values are: None, Total, Subtotal.
GetDisplayedColumnTitle Gets the currently displayed title of the specified column.
GetDynamicMethodList Returns a list of methods (including their signature) that can be dynamically invoked on this TestObject. (Inherited from TestObject)
GetParent Looks up the parent of this object in the test application. (Inherited from TestObject)
GetProperty Returns the value of the specified property. (Inherited from TestObject)
GetPropertyList Returns a list of property names that can be retrieved for the given object. (Inherited from TestObject)
GetRect Returns the size and position of this object. Per default the returned coordinates are relative to the parent window that contains this object. (Inherited from TestObject)
GetRowTotalLevel Gets the level of the row.
GetSymbolInfo Returns the description for the symbol in the cell.
GetToolbarButtonIcon Gets the name of the icon of the specified toolbar button.
GetToolbarButtonId Gets the ID of the specified tool bar button.
GetToolbarButtonText Gets the text of the specified tool bar button.
GetToolbarButtonTooltip Gets the tooltip of the specified tool bar button
GetToolbarButtonType Gets the type of the specified toolbar button. Possible values are: "Button", "ButtonAndMenu", "Menu", "Separator", "Group", "CheckBox".
GetToolbarFocusButton Gets the position of the current focused tool bar button
HasCellF4Help Returns true if the specified cell has a value help assigned.
HighlightObject Highlights this object. (Inherited from TestObject)
ImageClick Clicks on the specified image asset. (Inherited from TestObject)
ImageClickFile Clicks on the specified image. (Inherited from TestObject)
ImageExists Returns whether the specified image asset exists. (Inherited from TestObject)
ImageExistsFile Returns whether the specified image exists. (Inherited from TestObject)
ImageRectangle Returns the object-relative rectangle of the specified image asset. (Inherited from TestObject)
ImageRectangleFile Returns the object-relative rectangle of the specified image. (Inherited from TestObject)
InsertRows Inserts a range of rows
Invoke Dynamically invokes a method on the test object. (Inherited from TestObject)
InvokeMethods Dynamically invokes a sequence of methods starting at this TestObject. (Inherited from TestObject)
IsCellChangeable Returns true if the specified cell is changeable.
IsCellCheckBoxChecked Returns true if the check box at the specified position is checked.
IsCellHotspot Returns true if the cell is a link.
IsCellSymbol Returns true if the text in the cell is displayed in the SAP symbol font.
IsCellTotalExpander Returns true if the specified cell contains a total expander button.
IsColumnFiltered Returns true if the specified column is filtered.
IsColumnKey Returns true if the specified column is a key column.
IsFocused Return whether the control has focus. (Inherited from IFocusable)
IsToolbarButtonChecked Returns true if the specified tool bar button is checked.
IsToolbarButtonEnabled Returns true if the specified button is enabled.
IsTotalRowExpanded whether the specified total row is expanded.
ModifyCell Modifies the value of the specified cell.
ModifyCheckBox Modifies the value of the specified checkbox cell.
MoveRows Moves the rows with an index greater than or equal to fromRow up to an index less than or equal to toRow to the position of destRow.
PressButton Presses the button placed in the specified cell.
PressButtonCurrentCell Clicks a button placed in the current cell.
PressColumnHeader Clicks on the header of the specified column.
PressEnter Presses the enter key.
PressF1 Presses the F1 key.
PressF4 Presses the F4 key.
PressToolbarButton Clicks the specified button in the grid view's tool bar.
PressToolbarContextButton Opens the context menu of the specified button of the grid view's tool bar.
PressTotalRow Presses the row button of the specified total row.
PressTotalRowCurrentCell Presses the expansion button on the current cell.
SelectAll Selects the whole grid content (i.e. all rows and all columns).
SelectColumn Adds the specified column to the list of the selected columns.
SelectContextMenuItem Select an item from the controls context menu. (Inherited from ISapContextMenuable)
SelectContextMenuItemByPosition This method allows you to select a context menu item using the position of the item. (Inherited from ISapContextMenuable)
SelectContextMenuItemByText Select a menu item of a context menu using the text of the item and possible higher level menus. (Inherited from ISapContextMenuable)
SelectionChanged Notifies the server that the selection has changed
SelectToolbarMenuItem Selects an item from the context menu of the grid view's tool bar.
SetColumnOrder Sets the order of the columns.
SetColumnWidth Sets the width of the specified column.
SetCurrentCell Sets the specified cell as the current cell.
SetCurrentCellColumn Specifies the column of the current cell.
SetCurrentCellRow Sets the row of the current cell.
SetFirstVisibleColumn Sets the first visible column.
SetFirstVisibleRow Sets the first visible row.
SetFocus Gives focus to the control. (Inherited from IFocusable)
SetProperty Sets the value of the specified property. (Inherited from TestObject)
SetSelectedRows Selects the specified rows.
ShowContextMenu Shows the context menu of the control. (Inherited from SapComponent)
StartScreenRecording Starts screen recording (Inherited from TestObject)
StopScreenRecording Stops screen recording (Inherited from TestObject)
TextCapture Returns the text in this object's visible area. (Inherited from TestObject)
TextClick Clicks in the center of the specified text. (Inherited from TestObject)
TextExists Returns whether the specified text exists. (Inherited from TestObject)
TextRectangle Returns the object-relative rectangle of the specified text. (Inherited from TestObject)
TriggerModified Notifies the server of multiple changes in cells. Typically this method should be called after multiple calls to ModifyCell.
Verify Executes a verification on the given asset in the context of this UI object. (Inherited from TestObject)
WaitForChildDisappearance Waits until the specified child object does not exist or until the timeout is reached. If you don't explicitly pass a timeout using the optional timeout parameter, the timeout specified by the option OPT_WAIT_RESOLVE_OBJDEF will be used. An exception is thrown if the timeout is reached. (Inherited from TestObject)
WaitForDisappearance Waits until the object does not exist or until the timeout is reached. If you don't explicitly pass a timeout using the optional timeout parameter, the timeout specified by the option OPT_WAIT_RESOLVE_OBJDEF will be used. An exception is thrown if the timeout is reached. (Inherited from TestObject)
WaitForObject Waits for an object that matches the specified locator. If no object matches within an timeout an ObjectNotFoundException is thrown. The default timeout is 5 seconds and you can change the timeout by setting the value of the option OPT_WAIT_RESOLVE_OBJDEF. Use WaitForObject if the AUT takes a long time to display a specific object, for example when a transaction is processed before showing any results. By default, an action in the UI does not require a WaitForObject, because of the built-in synchronization. If you receive random timeout errors during normal script execution, consider increasing the default timeout instead of adding WaitForObject statements to your scripts. (Inherited from TestObject)
WaitForProperty Waits until the specified property has the specified value or until the timeout is reached.If you don't explicitly pass a timeout using the optional timeout parameter, the timeout specified by the option OPT_WAIT_RESOLVE_OBJDEF will be used. An exception is thrown if the timeout is reached. (Inherited from TestObject)
WaitForPropertyNotEquals Waits until the specified property has a value that is different to the specified value or until the timeout is reached.If you don't explicitly pass a timeout using the optional timeout parameter, the timeout specified by the option OPT_WAIT_RESOLVE_OBJDEF will be used. An exception is thrown if the timeout is reached. (Inherited from TestObject)
WaitForScreenshotStable Waits until the control is visually stable and does not change its position, by comparing screenshots taken with the specified interval. If you don't explicitly pass a timeout using the optional timeout parameter, the timeout specified by the option OPT_WAIT_SCREENSHOT_STABLE will be used. The default interval is 200 milliseconds. An exception is thrown if the timeout is reached. (Inherited from TestObject)