Automation testing QTP with VB Script functions Interview questions


Total available count: 68
Subject - Software Testing
Subsubject - Automation testing QTP with VB Script functions

Method: FolderExists?

It determines whether or not a specified folder exists.

Syntax: fso.FolderExists (folderspec)

Arguments:
fso: (Required) The name of a FileSystemObject object previously instantiated.
folderspec: (Required) The name of the folder whose existence is to be determined. A complete path specification (either absolute or relative) must be provided if the folder isn't expected to exist in the current folder.

Example:   

Set fso=createobject("Scripting.FileSystemObject")
'The Folder to check the existence.
folderpath="D:qtp"
If fso.FolderExists(folderpath)  then
 msgbox  "Folder Exists"
Else
 Msgbox "Folder doesnot Exist"
End If
Set fso=nothing

 




Next 5 interview question(s)

1
Method: GetDrive?
2
Method: GetFolder?
3
Method: GetFile?
4
Method: Close?
5
Method: Read?

Comments