Google Search Results
You arrived here after searching for the following phrases:
Click a phrase to jump to the first occurrence, or return to the search results.
Andrew Marin has shared the following QTip, which allows us to quickly and effectively delete all cookies in Internet Explorer.
This can be of great help to anyone who handles multiple user sessions during his tests, or just wants to reset the test environment before starting a test run.
Public Function ieDeleteCookies ()
SystemUtil.Run "iexplore",,,,0
WebUtil.DeleteCookies
SystemUtil.CloseDescendentProcesses
End Function
Thanks Andrew, for you great contribution!
Posted in Web


Yaron Assa




April 19th, 2009 at 6:12 pm
[…] AdvancedQTP placed an interesting blog post on Effectively delete cookiesHere’s a brief overviewAndrew Marin has shared the following QTip, which allows us to quickly and effectively delete all cookies in Internet Explorer. This can be of great help to anyone who handles multiple user sessions during his tests, or just wants to reset the test environment before starting a test run. […]
May 9th, 2009 at 8:34 am
Hi this method will delete the same thing as per user
just have a look
Delete Cookies and Temprary internet files VB QTP
rem ********************************
rem delete cookies
call fn_DeletesubFolderAndFiles(”C:\DOCUME~1\%USERNAME%\Cookies”)
rem *********************************
rem rem delete Temporary internet files
call fn_DeletesubFolderAndFiles(”C:\DOCUME~1\%USERNAME%\Locals~1\Tempor~1″)
rem ***********************************
REM *************************************************************************
REM Function fn_DeletesubFolderAndFiles(path)
Rem this Function delete the files & subfolder under the specified path
REM Input spath := Files path or parent Folder path
REM Output(ReturnType) := None
REM Note := IF file Protected then it will not delete without giving Error
REM *************************************************************************
Public Function fn_DeletesubFolderAndFiles(spath)
on Error Resume Next
rem Create File System object
set objFileSystem = CreateObject(”Scripting.FileSystemObject“)
rem Create Window Shel object
Set objWshShell = CreateObject(“WScript.Shell“)
Rem get Folderpath under which file present
Set objoFolder = objFileSystem.GetFolder(objWshShell.ExpandEnvironmentStrings(spath))
rem get count the files under the folder and loop run for delete the files
For Each oFile In objoFolder.files
On Error Resume Next
objFileSystem.DeleteFile oFile
Err.clear
Next
rem get count the subfolders under the folder and loop run for delete the subfolders
For Each oSubFolder In objoFolder.SubFolders
On Error Resume Next
objFileSystem.DeleteFolder oSubFolder
Err.clear
Next
rem clear the object
set objFileSystem = nothing
set objWshShell = nothing
set objoFolder = nothing
Err.clear
End function
http://rajivkumarnandvani.wordpress.com/