Partager via


Playback.EncryptText Method

Encrypts a given text for passing to playback as password property.

Namespace:  Microsoft.VisualStudio.TestTools.UITesting
Assemblies:   Microsoft.VisualStudio.TestTools.UITesting (in Microsoft.VisualStudio.TestTools.UITesting.dll)
  Microsoft.VisualStudio.TestTools.WindowsStore.UITesting (in Microsoft.VisualStudio.TestTools.WindowsStore.UITesting.dll)

Syntax

'Declaration
Public Shared Function EncryptText ( _
    textToEncrypt As String _
) As String
public static string EncryptText(
    string textToEncrypt
)
public:
static String^ EncryptText(
    String^ textToEncrypt
)
static member EncryptText : 
        textToEncrypt:string -> string
public static function EncryptText(
    textToEncrypt : String
) : String

Parameters

  • textToEncrypt
    Type: String

    The string to encode.

Return Value

Type: String
The encrypted text.

Remarks

This will encrypt the provided text with a key which is set with the SetEncryptionKeyLocation method. If the key file is not set, then this method will use a default key for encryption.

.NET Framework Security

See Also

Reference

Playback Class

Microsoft.VisualStudio.TestTools.UITesting Namespace

PlaybackSettings