SAPGuiEdit Object

Description

An edit box in an SAP GUI for Windows application.

Operations

The sections below list the built-in methods and properties that you can use as operations for the SAPGuiEdit object.

Note: You can also view a list and descriptions of the SAPGuiEdit description properties, for use in object repository descriptions, programmatic descriptions, checkpoint and output value steps, and as argument values for the GetTOProperty and GetROProperty methods.

Methods

Common Method CaptureBitmapSaves a screen capture of the object as a .png or .bmp image using the specified file name.
Common Method CheckChecks whether the actual value of an item matches the expected value.
Common Method CheckPropertyChecks whether the actual value of the specified object property matches the specified expected value within the specified timeout.
Common Method ChildObjectsReturns the collection of child objects contained within the object.
Common Method GetAllROProperties

Returns the collection of properties and current values from the object in the application.

Common Method GetROPropertyReturns the current value of the description property from the object in the application.
Common Method GetTOPropertiesReturns the collection of properties and values used to identify the object.
Common Method GetTOPropertyReturns the value of the specified description property from the test object description.
Common Method HighlightHighlights the object in the application.
Method OpenPossibleEntriesOpens the list of possible entries for the edit box.
Common Method OutputRetrieves the current value of an item and stores it in a specified location.
Common Method RefreshObjectInstructs UFT One to re-identify the object in the application the next time a step refers to this object.
Method SetSets the value of an edit box in an SAP GUI for Windows application.
Method SetCaretPosSets the position of the cursor within the edit box.
Method SetFocusSets the focus on an edit box object in an SAP GUI for Windows application.
Method SetSecureSets the encrypted value of an edit field.
Common Method SetTOPropertySets the value of the specified description property in the test object description.
Common Method ToStringReturns a string that represents the test object.
Common Method WaitPropertyWaits until the specified object property achieves the specified value or exceeds the specified timeout before continuing to the next step.

Properties

Common Property ExistChecks whether the object currently exists in the open application.
Common Property ObjectAccesses the native methods and properties of the object.

Back to top

 

OpenPossibleEntries Method

Description

Opens the list of possible entries for the edit box.

Syntax

object.OpenPossibleEntries

Return Type

None.

IMPORTANT

This method is not recorded. To add this method to your test, use the Step Generator or enter it manually in the Keyword View or . For more information, see the UFT One User Guide. When recording, UFT One records the actual operation, which is F4.

Example

Back to top

 

Set Method

Description

Sets the value of an edit box in an SAP GUI for Windows application.

Syntax

object.Set (Text)

Arguments

ParameterDescription
Text Required. A String value.
The text to be entered in the edit field.

Return Type

None.

Example

Back to top

 

SetCaretPos Method

Description

Sets the position of the cursor within the edit box.

Syntax

object.SetCaretPos (Position)

Arguments

ParameterDescription
Position Required. A long integer value.
The character position where you want to place the cursor. Values begin with 0.

Return Type

None.

IMPORTANT

This method is not recorded, but may be useful for edit boxes that are divided into active sections.

To add this method to your test, use the Step Generator or enter it manually in the Keyword View or Editor. For more information, see the UFT One User Guide.

Example

Back to top

 

SetFocus Method

Description

Sets the focus on an edit box object in an SAP GUI for Windows application.

Syntax

object.SetFocus

Return Type

None.

IMPORTANT

This method is recorded on the object that has the focus when information is sent to the SAP server during a recording session. This ensures that the focus is on the correct object during the test run.

Example

Back to top

 

SetSecure Method

Description

Sets the encrypted value of an edit field.

Syntax

object.SetSecure (EncryptedText)

Arguments

ParameterDescription
EncryptedText Required. A String value.
The encrypted text to be entered in the edit box.

Return Type

None.

IMPORTANT

The SetSecure method is not recorded. If you record in a password or other encrypted edit field, the Set method is recorded (For example, SAPGuiEdit("Password").Set "********"). To ensure that the correct value of an encrypted field is entered, change the Set method to a SetSecure method.

To find the encrypted value to use as the argument for the SetSecure method, use the Password Encoder utility (Start > All Programs > Micro Focus > Micro Focus UFT One > Tools > Password Encoder) or parameterize the argument and use the Data Table encryption option (right-click each unencrypted value in the password column and choose Data > Encrypt). For more information, see the UFT One User Guide.

While the SetSecure method enables you to hide passwords on the screen when running a test, it is not intended to be a secure way to protect password information.

Example

Back to top

See also: