SetText Method (String, Object[])

Microsoft Speech Platform SDK 11

Collapse imageExpand ImageCopy imageCopyHover image

Replaces the current content in a PromptBuilder object with a string and specifies formatting for the contents of the string.

Namespace:  Microsoft.Speech.Synthesis
Assembly:  Microsoft.Speech (in Microsoft.Speech.dll)

Syntax

Visual Basic (Declaration)
Public Sub SetText ( _
	textToSpeak As String, _
	ParamArray args As Object() _
)
Visual Basic (Usage)
Dim instance As PromptBuilder
Dim textToSpeak As String
Dim args As Object()

instance.SetText(textToSpeak, args)
C#
public void SetText(
	string textToSpeak,
	params Object[] args
)

Parameters

textToSpeak
Type: System..::..String

The new content for the PromptBuilder object.

args
Type: array<System..::..Object>[]()[][]

Objects that determine the formatting of the string specified by textToSpeak.

Remarks

This method calls ClearContent()()()() and then AppendText(String, array<Object>[]()[][]). The SetText(String, array<Object>[]()[][]) method uses the object array specified by args as parameters to Format()()()().

See Also