Sparrowlord Posted October 27, 2007 Posted October 27, 2007 Ok, I'm totally stumped on this one and I need some help. I'm trying to make a script that will help me carry cookies from pc to pc as I travel but I am having troubles with firefox. The code I have below is crappy but it almost gets the job done. $s_Firefox = 'HKLM\SOFTWARE\Mozilla\Mozilla Firefox' $s_FirefoxVersion = RegEnumKey($s_FireFox, 1) If @error Then $fff = 1 Else $fff = 2 If $fff = 2 Then $FileList=_FileListToArray(@AppDataDir & "\Mozilla\FireFox\Profiles") $cookies = @AppDataDir & "\Mozilla\FireFox\Profiles\" & $FileList[1] & "\cookies.txt" EndIf EndIf When I tested this on a computer without firefox it still reads this line: $cookies = @AppDataDir & "\Mozilla\FireFox\Profiles\" & $FileList[1] & "\cookies.txt" Then it throws an error and me and the script stops. I guess where I am getting at, how exactly am I going to know if it has firefox or not when it goes to copy over the file to my flash drive. I can't have it copy over where $fff = 2, I need to wait until the end of the script but when I get to: FileCopy($cookies, "E:\cookies\firefox\cookies.txt") How am I going to know if $cookies actually exists or not?
Moderators big_daddy Posted October 30, 2007 Moderators Posted October 30, 2007 Why not just use Portable Firefox.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now