Can somebody please let me know how to change my working directory? I would like the Save As feature to select a different path rather than having to navigate to it each time I save. thanks
It's held in the registry, run this from QTP or VBScript to change the key:
sHiveAbbrv = "HKLM"
sAssignmentType = "REG_SZ"
tDir = "C:\QTP\MyDirectory" ' This is where you want default tests directory to be
Set oWshell = CreateObject("WScript.Shell")
sRegKeyPath = "SOFTWARE\Mercury Interactive\QuickTest Professional\MicTest\"
sRegValueName = "TestsDirectory"
sAssignmentValue = tDir
sRegCreatePathString = Trim(sHiveAbbrv) & "\" & Trim(sRegKeyPath) & "\" & Trim(sRegValueName)
oWshell.RegWrite sRegCreatePathString, sAssignmentValue, sAssignmentType
Set oWShell = Nothing
My linkedIn Profile
A good rule of thumb is to never measure with your thumb.
Thanks Mark. I will give that a try!
that did not work, but thanks for the reply...
1. Start -> Run
2. Type regedit and click OK
3. HKEY_LOCAL_MACHINE -> SOFTWARE -> Mercury Interactive -> QuickTest Professional -> MicTest
4. Edit the value "TestsDirectory"
Thanks Mark. that worked!