You can use the functions described in this section in any script in application plan types. These functions are only effective in capturing values from Microsoft Internet Explorer pages. They are useful with the Internet Explorer LearnMode type.
IECapture
This function captures the data from Internet Explorer in the form of name/value pairs and stores them for subsequent searches. It returns the number of pairs found.
- Syntax
- IECapture (bool useTDtags, HWND hwndSelectedWind)
- Arguments
- useTDTags: use this boolean if LTD tags need to be captured.
- Example
- size = IECapture(false, 0)
- Results
- 0: <PEB#1>,"Student Name:"
- Example
- size = IECapture(true, 0)
- Results
- 0: <LTD#1>, “Student Name:”
IECaptureEx
This function captures a specified set of named fields from Internet Explorer and stores them for subsequent searches.
- Syntax
- IECaptureEx (bool useTDtags, HWND hwndSelectedWind, VARIANT* pVarIDs)
- Arguments
- useTDTags: use this boolean if LTD tags need to be captured.
- Example
- myArray = Array(“CSID”, “CSID2”
- Results
- 0: CSID, “12n53n43”
- Example
- myArray = Array(“”)
- Results
- 0: <LTD#1>, “Student Name:”
IEGetNameByIndex
This function returns the name at the specified index.
- Syntax
- IEGetNameByIndex (int nIndex)
- Arguments
- nIndex: specifies the location of the tag. Zero returns the first tag.
- Example
- name = IEGetNameByIndex(1)
- Results
- name = “<LTD#2>”
IEGetValueByIndex
This function returns the value at the specified index.
- Syntax
- IEGetValueByIndex (int nIndex)
- Arguments
- nIndex: specifies the location of the value. Zero returns the first value.
- Example
- value = IEGetValueByIndex(1)
- Results
- value = “Smith, James”
IEFindName
This function allows you to search for a name and it returns the location where it was found. It returns -1 if not found.
- Syntax
- IEFindName (LPCTSTR name, int nStart, bool bCaseSensitive)
- Arguments
- Name: specifies the name to search for.
- Example
- nameLocation = IEFindName (“<PEB#1>”, 0, false)
- Results
- nameLocation = 8
IEFindNameReverse
This function allows you to search for a name in reverse and it returns the location where it was found. It returns -1 if not found.
- Syntax
- IEFindNameReverse (LPCTSTR name, int nStart, bool bCaseSensitive)
- Arguments
- Name: specifies the name to search for.
- Example
- nameLocation = IEFindNameReverse (“<PEB#1>”, 6, true)
- Results
- nameLocation = -1
IEFindValue
This function allows you to search for a value and it returns the location where it was found. It returns -1 if not found.
- Syntax
- IEFindValue (LPCTSTR value, int nStart, bool bCaseSensitive)
- Arguments
- Value: specifies the value to search for.
- Example
- valuelocation = IEFindValue(“Student Name:”, 0, true)
- Results
- valueLocation = 0
IEFindValueReverse
This function allows you to search for a value in reverse and it returns the location where it was found. It returns -1 if not found.
- Syntax
- IEFindValueReverse (LPCTSTR value, int nStart, bool bCaseSensitive)
- Arguments
- Name: specifies the value to search for.
- Example
- valueLocation = IEFindValueReverse(“Student Name:”, -1, true)
- Results
- valueLocation = 8
IEGetValue
This function returns the value when passed the name of the name/value pair.
- Syntax
- IEGetValue (LPCTSTR value, bool bCaseSensitive)
- Arguments
- Name: specifies the name to search for.
- Example
- WorkingValue = IEGetValue (“<LTD#12>”)
- Results
- The value, which corresponds to the name <LTD#12>, is placed into folder.
IEGetValueByName
This function allows you to search for a name and it returns the corresponding value. It returns an empty string if not found.
- Syntax
- IEGetValueByName (LPCTSTR name, bool bCaseSensitive)
- Arguments
- Name: specifies the name to search for.
- Example
- value = IEGetValueByName(“<PEB#1>”, false)
- Results
- value = “Student Name:”
The Test button in the script editor does not always return valid results when you use these functions. To test your code, save the template, close the application plan, and then click the icon in the Perceptive Content toolbar to view the results.