INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Glynor's Settings Saving Script  (Read 17504 times)

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Glynor's Settings Saving Script
« on: September 29, 2006, 02:51:10 pm »

Due to popular demand (on this thread over here), I've cleaned up and made available my script that can be used to automate the saving of the HKCU/Software/JRiver/ registry key which contains all of the "settings" for MC11.1 and MC12 that aren't part of the Library itself.  Because it saves the entire JRiver key, it will save settings for both MC11 and MC12 (it might even work with older versions if that's where they save their settings too).

Please note: Because MC's registration is machine specific, this script does NOT save the contents of HKLM/Software/JRiver, and it will not restore your registration information.  This must be done manually (like normal) if you do a fresh install or reinstall MC completely.

You can then restore these settings on another computer or on your computer after a un/re-install by simply double clicking on the REG file it creates.  The script also saves the REG file it created last time (meaning a backup of the last copy it created) to a file called "previous.reg", so you have the option of "going back one version" if needed.

Click here to download it!

Current Version: 1.05

Compatibility and Requirements:

This script will work out-of-the-box on any Windows XP computer.  It will also work with Windows 2000 if you have the Resource Kit Support Tools from Microsoft installed (these are free).  Specificially, it requires the program REG.EXE (which performs the actual saving of the Registry keys).

To download these tools for Windows 2000 SP4 go here:

http://www.microsoft.com/windows2000/downloads/servicepacks/sp4/supporttools.mspx

You can also install the Support Tools directly from your Windows 2000 install disc (though if you don't have a slipstreamed copy of the Service Pack 4 install, then it would be best to use the link above and download the updated versions).  Instructions for installing the tools from CD are here:

http://support.microsoft.com/kb/301423

If you happen to be running Windows NT or 98/ME, the REG.EXE program is available for those platforms as well.  You can download the NT version here:

http://www.petri.co.il/download_free_reskit_tools.htm

There was a version available for 98 and ME in the Resource Kit tools.  I haven't found a download specifically for this version of the tool, but you could try the NT one available above as it will likely work.  Simply extract it to your System32 directory (inside the Windows directory).

For both Windows NT and Windows 98/ME you will also need to install the latest version of the Windows Script Host utilities.  They are available here free from Microsoft:

http://www.microsoft.com/downloads/details.aspx?FamilyId=0A8A18F6-249C-4A72-BFCF-FC6AF26DC390&displaylang=en

To install this script:

Simply extract it to C:\scripts\MC_Scripts\.  If you want to save it to a different location, you'll need to edit the script to tell it where you put it (this is easy and is documented in the script itself).

To run the script:

Simply double click on the MC_Settings-Save.wsf file.  You can also start it by going to the Start --> Run and browsing to where you saved the script.

If this doesn't work, you may not have WSH installed (or it may be disabled).  See the instructions below in this thread to reinstall or re-associate it.

You'll notice that the script pops up a message box when it's done, telling you that it worked and where it saved the file.  This message box conveniently auto-closes after 10 seconds.  However, if you don't want it do do this at all (for using it with Scheduled Tasks for example), simply run the script with the /verbosity:off command line option.  For example:

Code: [Select]
C:\scripts\MC_Scripts\MC_Settings-Save.wsf /verbosity:off
If you want to set up a Scheduled Task with this option:

1. Open the Scheduled Tasks dialog (Start All Programs --> Accessories --> System Tools --> Scheduled Tasks).
2. Click "Add Scheduled Task" and click "Next" in the wizard that appears (it will then take a few minutes to build it's list).
3. Click Browse and navigate to locate where you installed the script.  Select it and click "Open" (or double click on the script).
4. Choose how often you'd like to run the script.
5. Choose when you'd like it to run.
6. Enter your account's password twice if needed.
7. Check the "Open advanced properties" box, and click Finish.
8. In the Run box, add the "/verbosity:off" option next to the script's filename (it should look like the command line shown above).
9. Click OK and re-enter your password (twice) if it asks.

If you use MC to do MP3 encoding with LAME:

After a re-install (or fresh install) but before you restore your settings, you'll want to go into MC and go to Tools --> Options --> Encoding and select MP3 encoder at least once.  This is because the first time you choose MP3 Encoder, MC downloads and installs LAME.  If you just restore your settings without doing that first, MC will get confused because it won't have installed LAME (but because of the settings restore it already "thinks" it already has).  Once you do this, you can close MC and restore your settings.

If you forget to do this, just go into Tools --> Options --> Encoding and set one of them to something else (like APE) and then close out of the Options dialog.  Open it back up again and re-select MP3 and it should properly download and install LAME that time.

To restore your settings saved with this script:

1. Make sure MC is closed!
2. Go to the folder where you installed the scripts.
3. Locate the file called "current.reg".  This file will contain the settings from the most recent time you ran the script.  Once you've run the script more than once, there will also be a file called "previous.reg", which contains the settings from the previous time you ran the script (which serves as a backup).
4. Double click on the "current.reg" file and answer yes when Windows asks if you're sure.
5. You should see the results immediately the next time you open MC.

If you have any questions, just ask!
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #1 on: September 29, 2006, 10:02:21 pm »

Glynor,

If I understand this correctly, this is a great tool.  I can save all of the settings that are lost when occasionally I have to un-install & re-install MC.  I can also use it to set up a second PC.  So I downloaded & installed it (unzipped into the proper directory). 

The only problem is I have no idea how to run the script.  Either for the backup or the restore.  Hopefully this isn’t too dumb of a question.

Randy
Logged

alanl

  • Junior Woodchuck
  • **
  • Posts: 76
Re: Glynor's Settings Saving Script
« Reply #2 on: September 30, 2006, 05:53:49 pm »

Thanks for that Glynor.  Perhaps you should note in the comments that short filenames should be used if changing the default location.  I couldn't get it to work until I changed "D:\My Documents\Media Centre\RegBackup\" to "D:\MyDocu~1\MediaC~1\RegBackup\". 

Whatever, thanks anyway.  I always seem to be re-installing MC and losing all my settings.  This should sort it.
Logged

alanl

  • Junior Woodchuck
  • **
  • Posts: 76
Re: Glynor's Settings Saving Script
« Reply #3 on: September 30, 2006, 06:01:16 pm »

Magic_Randy:  It should just run when you double-click the file  (it uses Windows script host).  You can edit it using notepad.  If that doesn't work for you, sorry I don't know enough to advise - perhaps some of the gurus on this forum can help?
Logged

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #4 on: September 30, 2006, 06:24:00 pm »

Magic_Randy:  It should just run when you double-click the file  (it uses Windows script host).  You can edit it using notepad.  If that doesn't work for you, sorry I don't know enough to advise - perhaps some of the gurus on this forum can help?

If I double click on it, notepad opens the file.
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #5 on: September 30, 2006, 07:37:00 pm »

If I double click on it, notepad opens the file.

What OS are you using?  The script should run in Windows Scripting Host.  I'm not sure when that was first offered, but it might be Windows 98 and up.

If you're using98, ME, 2000, or XP and double clicking it opens it in Notepad, then somehow your file associations got messed up.  You might have done something like this to prevent "script virus infection" a while back when those were common.  This isn't really necessary though, as any good AV program will protect you from "bad" scripts.

To re-enable it you'll want to associate those WSF files with Wscipt.exe (which should be in your C:\Windows\System32\ directory.  To do this, select the file, right click and choose Open With.  Choose "Choose Program" and either find Microsoft Windows Based Script Host in the list and check the "always use the selected program" box, or click browse and find Wscript.exe (and check the box).  If you don't have a Wscript.exe file in the System32 directory, it somehow got uninstalled.  You can download a version for your OS here:

http://msdn.microsoft.com/library/default.asp?url=/downloads/list/webdev.asp

If I understand this correctly, this is a great tool.  I can save all of the settings that are lost when occasionally I have to un-install & re-install MC.  I can also use it to set up a second PC.  So I downloaded & installed it (unzipped into the proper directory). 

You do understand.  That is exactly it's purpose.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #6 on: September 30, 2006, 07:37:39 pm »

Thanks for that Glynor.  Perhaps you should note in the comments that short filenames should be used if changing the default location.  I couldn't get it to work until I changed "D:\My Documents\Media Centre\RegBackup\" to "D:\MyDocu~1\MediaC~1\RegBackup\". 

Whatever, thanks anyway.  I always seem to be re-installing MC and losing all my settings.  This should sort it.

It shouldn't be this way.  I forgot a set of quotes somewhere.  I'll look at it tomorrow or Monday and fix it with a new version.  Using the "short filename" is a good workaround.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #7 on: September 30, 2006, 09:09:32 pm »

What OS are you using?  The script should run in Windows Scripting Host.  I'm not sure when that was first offered, but it might be Windows 98 and up.

If you're using98, ME, 2000, or XP and double clicking it opens it in Notepad, then somehow your file associations got messed up.  You might have done something like this to prevent "script virus infection" a while back when those were common.  This isn't really necessary though, as any good AV program will protect you from "bad" scripts.

To re-enable it you'll want to associate those WSF files with Wscipt.exe (which should be in your C:\Windows\System32\ directory.  To do this, select the file, right click and choose Open With.  Choose "Choose Program" and either find Microsoft Windows Based Script Host in the list and check the "always use the selected program" box, or click browse and find Wscript.exe (and check the box).  If you don't have a Wscript.exe file in the System32 directory, it somehow got uninstalled.  You can download a version for your OS here:

http://msdn.microsoft.com/library/default.asp?url=/downloads/list/webdev.asp

You do understand.  That is exactly it's purpose.

Thanks - all of that worked just fine (BTW - I'm using XP).

Now for dumb question 2:

So now that I have it backed up, how do I do a restore.
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #8 on: September 30, 2006, 09:35:05 pm »

Now for dumb question 2:

So now that I have it backed up, how do I do a restore.

Make sure MC is closed.  Then just double click on the file called "current.reg" that the script creates in it's directory, then answer "yes" when it asks "are you sure?".  You can copy this REG file over to another computer and double click on it there.

BTW: When you run the script for a second time, it will create a file called "previous.reg".  This file is the saved settings from the previous time you ran the script.  This is nice because it lets you "go back" if you mess up somehow and change a setting you didn't like but can't find it.

Also, note the new LAME-related instruction I added to my original post on this thread.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #9 on: September 30, 2006, 09:49:06 pm »

Glynor,

Thanks... 

I wish I was paying more attention earlier.  This would have saved me alot of hastle.

Now all I need to do is figure out how to move smartlists around (without having to take the whole library).

Randy
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #10 on: September 30, 2006, 10:02:37 pm »

No problem at all!  I'm happy to help!  (I'm just glad this is coming in handy for some people.)

I updated the instructions in the original post to be much more clear.  Hope this helps!
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #11 on: September 30, 2006, 10:08:39 pm »

I need to do is figure out how to move smartlists around (without having to take the whole library).

If only this were possible...
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

AoXoMoXoA

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1551
  • I am a kangaroo . . . . no, really!
Re: Glynor's Settings Saving Script
« Reply #12 on: October 01, 2006, 11:09:30 am »

When I run this script, I get the dialog box stating that the reg file has been saved, however there is no reg file there!
Yet the log shows a sucessful completion:
PC1 : MC_Settings-Save started: Sun 10/01/2006 11:57:14.79
PC1 : MC_Settings-Save finished: Sun 10/01/2006 11:57:17.59
PC1 : MC_Settings-Save started: Sun 10/01/2006 12:04:00.07
PC1 : MC_Settings-Save finished: Sun 10/01/2006 12:04:10.72

Any ideas?

MC11.1
Win2K
Logged
. . . the game is rigged

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #13 on: October 01, 2006, 11:17:05 am »

When I run this script, I get the dialog box stating that the reg file has been saved, however there is no reg file there!

Look in c:\scripts\mc_scripts\.  There should be a file called current.reg.  That is your backup.
Logged

AoXoMoXoA

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1551
  • I am a kangaroo . . . . no, really!
Re: Glynor's Settings Saving Script
« Reply #14 on: October 01, 2006, 12:30:59 pm »

Look in c:\scripts\mc_scripts\.  There should be a file called current.reg.  That is you backup.
Yes, I read that and looked there, the file is not in existence in that folder or elsewhere (I also used the Windows search function and it is not found).
Logged
. . . the game is rigged

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #15 on: October 01, 2006, 02:24:44 pm »

Yes, I read that and looked there, the file is not in existence in that folder or elsewhere (I also used the Windows search function and it is not found).

Don't know what to say.  That is where it goes to on my PC.  If it does not show up, even when you do a search, my guess is that the script did not process correctly. 

Did you make any changes to the script?  Is it in the location suggested?
Logged

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9139
Re: Glynor's Settings Saving Script
« Reply #16 on: October 01, 2006, 02:31:21 pm »

Glynor, I have not d'loaded these files, and probably won't, as Genie backup manager makes a backup of my reg entries along with all the other files I need for a real, full, MC backup.

A quick question though, if I may...

You 1st mentioned using the scripting host to hide the cmd window in my 'image management' thread. I recoiled...

Is it possible to use scripting to get the image copied, opened in photoshop....

This part is doable without a problem, I believe, and photoshop opens in the foreground with the image present for editing....

so, i edit it, then save it, and then close the image, not photoshop itself, just the image, and at that point, I'd like the script to return MC to the forefront, and then end.

If you think that's attainable, without the need of a scripting degree, I would probably sit down and try to learn how. I'd really like to get this system into useable shape for MC12. It's not really that practical for 11.1 due to its lack of auto-import.

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #17 on: October 01, 2006, 03:39:26 pm »

When I run this script, I get the dialog box stating that the reg file has been saved, however there is no reg file there!
Yet the log shows a sucessful completion:
PC1 : MC_Settings-Save started: Sun 10/01/2006 11:57:14.79
PC1 : MC_Settings-Save finished: Sun 10/01/2006 11:57:17.59
PC1 : MC_Settings-Save started: Sun 10/01/2006 12:04:00.07
PC1 : MC_Settings-Save finished: Sun 10/01/2006 12:04:10.72

The popup and log don't really confirm that the script did it's "thing" properly, just that it finished running without generating an error.  I suspect too that it's being caused by moving it to a different directory, but that should work (right now you need to use short filenames).  One other thing that might be required (I'm not sure) is running the script with Administrative privledges since it accesses the Windows Registry (it's read-only but that still could be it).  If you're running as a limited user, that could be the issue.  I'm just guessing though...

Obviously the script needs to do some better logging...

I'll get on it tonight or tomorrow, it shouldn't be hard to fix (or at least get the logging to help us diagnose what's going on).  Check back here soon.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #18 on: October 01, 2006, 03:41:46 pm »

so, i edit it, then save it, and then close the image, not photoshop itself, just the image, and at that point, I'd like the script to return MC to the forefront, and then end.

This might be very tough without resorting to Girder.  I'll have to test something though to be sure.

Detecting that Photoshop was closed would probably be a simple matter, but I understand why you wouldn't want it to work that way (Photoshop isn't exactly light-weight).

I'll do some digging when I work on fixing the above issue and see what I come up with....
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #19 on: October 01, 2006, 03:56:32 pm »

Yes, I read that and looked there, the file is not in existence in that folder or elsewhere (I also used the Windows search function and it is not found).

Glynor is looking at this - but did you install the script in the folder it is supposed to be installed in - without edits?
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #20 on: October 01, 2006, 05:54:28 pm »

1.04 - 20061001

  • FIXED: Bug in the section of the script that saved the old version
  • FIXED: Script wouldn't work if moved to a directory that contained spaces in the path (missing quotes)
  • NEW: Improved logging should capture error output from commands run to log, and notes where the resulting "current.reg" file will be saved.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #21 on: October 01, 2006, 05:58:21 pm »

So.... Download the new version as it has much better logging (rather than the relatively useless stuff before) and I found a bug in one section of the script that could cause problems.  I did also fix the directory with spaces issue discussed above.

Let me know if this one still doesn't work, and post the log (which should actually have some real info now).

If it still doesn't work, the only other thing I can think of other than the Administrative account thing is that Windows 2000 might work somewhat differently when dealing with the registry REG command.  If so, I might have to re-work the script to actually do the registry commands through WSH instead of using the REG command line utility (which is convenient so I hope not).

Marko... I'm still working on it.  Give me a bit.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #22 on: October 01, 2006, 06:14:41 pm »

Marko -

Doesn't look like it's possible (or if so, it's beyond my WSH knowledge).  Using a WSH command like this works, but only if you close Photoshop every time after you're done:

Code: [Select]
WshShell.Run """C:\Program Files\Adobe\Adobe Photoshop CS2\Photoshop.exe"" """ & strInputFile & """", 5, True
Obviously this isn't ideal.

If you wanted to though, you could use Girder 4 to accomplish the goal.  You could script the open code (using a command like what I posted above but with False at the end instead), then in the next line call a command to "enable" a specially constructed Girder GML file that watches for Photoshop to be minimized (or maybe it could even detect the photo window being closed -- actually, I bet it could) after which the Girder GML could re-activate MC for you and re-disable itself.

Of course, it might just be easier to close the file and re-activate MC yourself with that amount of complexity needed...  ;)
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

AoXoMoXoA

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1551
  • I am a kangaroo . . . . no, really!
Re: Glynor's Settings Saving Script
« Reply #23 on: October 01, 2006, 07:25:44 pm »

1.04 - 20061001

  • FIXED: Bug in the section of the script that saved the old version
  • FIXED: Script wouldn't work if moved to a directory that contained spaces in the path (missing quotes)
  • NEW: Improved logging should capture error output from commands run to log, and notes where the resulting "current.reg" file will be saved.
Sorry, the page you requested was not found.
Logged
. . . the game is rigged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #24 on: October 01, 2006, 07:29:50 pm »

Sorry, the page you requested was not found.

It was working for me when I just tested it, but I'm sure it might have been the stupid Geocities hourly transfer limit causing problems again.  I moved the file over to my Adelphia account and all should be good now.

Sorry about that!
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #25 on: October 01, 2006, 07:50:19 pm »

I installed v1.4 and it does not work.  I can find no files after I run it (e.g. no current.reg, etc.).  It did work with the prior version.
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #26 on: October 01, 2006, 08:53:50 pm »

Does it generate a log?

Nevermind.  My bad.  I zipped the wrong version.  Hold on...

EDIT: Serves me right for designing it to be installed in one place, but actually using it myself with it installed in a different place.  I accidentally uploaded my "edited" version rather than the real "development" version, so it was trying to save to drive U:\ which (of course) you probably don't have.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #27 on: October 01, 2006, 09:00:12 pm »

1.05- 20061001

  • FIXED: Corrected bad default strMyDirectory entry.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #28 on: October 01, 2006, 09:45:52 pm »

1.05- 20061001

  • FIXED: Corrected bad default strMyDirectory entry.
glynor,

thanks... everything works fine now - randy
Logged

LedZep

  • Recent member
  • *
  • Posts: 24
Re: Glynor's Settings Saving Script
« Reply #29 on: October 21, 2006, 04:51:17 pm »

Tanks to Glynor !!!
I just installed MC on a new Computer.
It worked fine for me.
Your script came right in time ...

Cheers
Henning
Logged

AoXoMoXoA

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1551
  • I am a kangaroo . . . . no, really!
Re: Glynor's Settings Saving Script
« Reply #30 on: October 22, 2006, 12:32:22 pm »

hmmm, I still do not get a saved file:

C1 : MC_Settings-Save started: Sun 10/22/2006 13:34:18.68
C1 : MC_Settings-Save Resaving old current.reg as backup
The system cannot find the file specified.
C1 : MC_Settings-Save Saving HKCU/Software/JRiver to: C:\scripts\MC_Scripts\current.reg
'reg' is not recognized as an internal or external command,
operable program or batch file.
C1 : MC_Settings-Save finished: Sun 10/22/2006 13:34:21.56

No config file is created or saved.



MC12, Windows 2000 SP4
Logged
. . . the game is rigged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #31 on: October 23, 2006, 10:36:09 am »

The script calls an application called REG which actually handles the reading of the registry keys.  I'm wondering now, from those errors, if Windows 2000 doesn't come with that program (possibly it's an XP only thing).

I'll look into it.

EDIT:  Yes.  I've confirmed this.  REG.EXE comes with Windows XP by default, but it is not included with Windows 2000 or Windows NT.  It is available as part of the free Resource Kit tools though.  You can download it individually here (you want the program called just REG):

http://www.petri.co.il/download_free_reskit_tools.htm

Once you download it, you'll want to extract the REG.EXE file from the ZIP archive, and put it in your System32 directory (inside the Windows directory).


EDIT AGAIN: Actually, just install the Support Tools.  It has a newer version than on petri.co.

If you'd rather just install all of the Resource Kit Support Tools (that's probably what I'd do because others in the pack are very useful too), you can download them directly from Microsoft here:

http://www.microsoft.com/windows2000/downloads/servicepacks/sp4/supporttools.mspx

Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

marko

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 9139
Re: Glynor's Settings Saving Script
« Reply #32 on: October 25, 2006, 02:47:11 am »

glynor, thanks for looking into it for me.
I actually forgot about this thread and went in search of some info this morning after finding that adding /wait to the line didn't actually cause it to wait....
the next line was simply mc12.exe /start, which brings mc to the front if it's already running, and worked as predicted, without the wait, of course....

I found this quote on a M$ page...

Quote
When you run a 32-bit graphical user interface (GUI) application, cmd does not wait for the application to quit before returning to the command prompt. This new behavior does not occur if you run the application from a command script.

sigh! it's just soooo tiresome having to go down and click in the taskbar after closing an image :)

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #33 on: October 25, 2006, 09:43:36 am »

sigh! it's just soooo tiresome having to go down and click in the taskbar after closing an image :)

I know!  The horror of it all!   ;)
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

runemail

  • Regular Member
  • World Citizen
  • ***
  • Posts: 205
  • Soft Rock
Re: Glynor's Settings Saving Script
« Reply #34 on: November 02, 2006, 06:57:24 am »

Just tried this in vista (Exported settings from xp
), and the "auto import settings" did not import.


Should they?

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #35 on: November 02, 2006, 10:10:44 am »

I don't believe so.  They are saved on a per-library basis (rather than per-user), so I'd guess that the settings themselves are saved within the library database files.  I'm not sure though!
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #36 on: November 03, 2006, 02:00:46 am »

glynor,

Your script is really appreciated, but I'm wondering why a function like this is not provided as part of MC.  I know you are very active with MC and the forum, has there been some push back from the J River team that caused you to develop it yourself?

Randy
Logged

glynor

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 19608
Re: Glynor's Settings Saving Script
« Reply #37 on: November 03, 2006, 10:17:03 am »

Your script is really appreciated, but I'm wondering why a function like this is not provided as part of MC.  I know you are very active with MC and the forum, has there been some push back from the J River team that caused you to develop it yourself?

I never asked.  I needed it, it was possible, so I just did it myself.
Logged
"Some cultures are defined by their relationship to cheese."

Visit me on the Interweb Thingie: http://glynor.com/

Magic_Randy

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 2367
  • I used to be indecisive, but now I'm not so sure..
Re: Glynor's Settings Saving Script
« Reply #38 on: November 03, 2006, 10:39:19 am »

I never asked.  I needed it, it was possible, so I just did it myself.

OK... That explains it.  It just appeared to be a logical standard feature. 
Logged

gappie

  • Guest
Re: Glynor's Settings Saving Script
« Reply #39 on: November 04, 2006, 09:08:26 am »

this is great!  8)

im rebuiling my machine at a regular basis :-\. this is something i really missed.

Logged

AoXoMoXoA

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 1551
  • I am a kangaroo . . . . no, really!
Re: Glynor's Settings Saving Script
« Reply #40 on: November 04, 2006, 06:27:40 pm »

Glynor,
Just wanted to let you know that although I could not get it working before (W2K) since doing an OS reinstall it is working for me now in WinXP.
Thanks, this was sorely needed.
Logged
. . . the game is rigged

hit_ny

  • Citizen of the Universe
  • *****
  • Posts: 3310
  • nothing more to say...
Re: Glynor's Settings Saving Script
« Reply #41 on: December 20, 2006, 02:55:58 pm »

Just noticed this when searching for a way to migrate registry settings from 11.1->12. Agreed for same version upgrades, the export from registry of the HKCU/J River key does the trick.

turns out some of the keys i wanted to transfer over are the same between the two versions. So looked for a tool that would export just specific values (presets, favorites, external tools etc) to a reg file.

Regedit only exports keys and not specific values, so played about with a few tools i found on the net and Reg Scanner fit the bill.

Edit saved reg file, change Media Center 11->12 and dbl click to load keys back into the registry.
Logged

MarkCoutinho

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 676
Re: Glynor's Settings Saving Script
« Reply #42 on: May 17, 2008, 04:39:15 pm »

Glynor, you're the greatest! This was a nag-thing for me every time I installed MC on a new machine. Now I'm saved in the future.
Logged
Mark Coutinho
Dutch Top 40 collector of lyrics, sleeves and bios

HTPC4ME

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 2760
  • LIFE IS A RADIO... CRANK IT UP TO 11!
Re: Glynor's Settings Saving Script
« Reply #43 on: September 21, 2008, 02:55:01 am »

hi Glynor

Will this work for 13 as well?
Logged

JONCAT

  • Guest
Re: Glynor's Settings Saving Script
« Reply #44 on: October 31, 2008, 10:07:25 am »

Same question. Can I backup 12 and apply to 13?

DC
Logged

JONCAT

  • Guest
Re: Glynor's Settings Saving Script
« Reply #45 on: October 31, 2008, 04:07:13 pm »

Link is dead...

dc
Logged

RiderFan

  • Guest
Re: Glynor's Settings Saving Script
« Reply #46 on: March 12, 2009, 11:58:53 pm »

Has anyone got this to work with MC13?
Logged

HTPC4ME

  • Regular Member
  • Citizen of the Universe
  • *****
  • Posts: 2760
  • LIFE IS A RADIO... CRANK IT UP TO 11!
Re: Glynor's Settings Saving Script
« Reply #47 on: March 13, 2009, 12:57:07 am »

haven't heard as of yet.
Logged
Pages: [1]   Go Up