IsStringSupported function (recapis.h)
Returns a value that indicates whether a word, date, time, number, or other text that is passed in is contained in the dictionary.
The results of this test depend on the factoid setting.
Syntax
HRESULT IsStringSupported(
HRECOCONTEXT hrc,
ULONG wcString,
const WCHAR *pwcString
);
Parameters
hrc
The handle to the recognizer context.
wcString
The count, in Unicode (wide) characters, of pwcString.
pwcString
The Unicode (wide) characters to test.
Return value
This function can return one of these values.
Return code | Description |
---|---|
|
Success.
This function also returns S_OK if the recognizer does not support this function. |
|
Unable to allocate memory to complete the operation. |
|
The string is not supported. |
|
One of the parameters is an invalid pointer. |
|
An unspecified error occurred. |
|
An invalid argument was received. |
Remarks
This function is optional.
The results of this test depend on the factoid setting. For example, if the factoid setting is set to default, then "hello","555-1234", and "10/19/2002" all return S_OK. However, if the factoid is set to TELEPHONE, only "555-1234" returns S_OK, the others return S_FALSE. For more information about factoids, see Supported Factoids from Version 1.
Note that this function should take into consideration any information specified in SetTextContext when returning a value. For example, if the recognizer receives calls to SetTextContext ("http:", "") and receives a URL factoid, SetFactoid ((!IS_URL)) then IsStringSupported("www.microsoft.com") should return S_FALSE because it is missing the "//".
The COERCE flag has no effect on IsStringSupported.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP Tablet PC Edition [desktop apps | UWP apps] |
Minimum supported server | None supported |
Target Platform | Windows |
Header | recapis.h |
DLL | inkobjcore.dll |