# INSERT
Description:
This method is used to add a new folder path to the Folders list (Tools-> Options-> Folders).
Syntax:
PathFinder.Insert [Path],[Index]Example:
PathFinder.Insert "C:\Test",0The above example will add new folder path to the Folders list.
# FIND
Description:
This method returns the Index of the specified path.
Syntax:
Msgbox PathFinder.Find [Path]Example:
Msgbox PathFinder.Find("C:\Test")The above example returns the Index of the specified path. If the path is not found, it will return -1.
# MOVEITEM
Description:
This method can be used to swap the Index of two folder paths.
Syntax:
Pathfinder.MoveItem [Source_Index],[Destination_Index]Example:
Pathfinder.MoveItem 1,0
# REMOVE
Description:
This method removes the specified folder path from the folders list.
Syntax:
Pathfinder.Remove [Path]Example:
Pathfinder.Remove("C:\Test")
# REMOVEALL
Description:
This method removes all the items from the folders list.
Syntax/Example:
Pathfinder.RemoveAllNote: It removes default folder item as well.
# REMOVEBYINDEX
Description:
This method removes the folder path item using Index.
Syntax:
PathFinder.RemoveByIndex([Path_Index])Example:
PathFinder.RemoveByIndex(0)
# SAVE
Description:
This method can be used to commit all the changes which are done using PathFinder object. If Save method is not used, your changes in Folder List will not be retained.
Syntax/Example:
PathFinder.Save
Add the following 2 to your list
ReplyDelete' Returns current test path, similar to environment("TestDir")
PathFinder.CurrentTestPath
'Returns number of paths listed in the current session
PathFinder.Count
Awesome list
ReplyDeleteWhats the difference between the QTP object provided methods and this one. eg. Create an Instance of QTP
ReplyDeleteset obj=Createobject("Quicktest.application")
obj.folders.removeall
this functions does the same thing which Pathfinder.RemoveAll does... Is there any significance in this ?