Computing.Net > Forums > Windows 95/98 > How to Replace path in registry

Computing.Net: Over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to sign up now, it's free!

How to Replace path in registry

Reply to Message Icon

Original Message
Name: moonnightingale
Date: July 23, 2004 at 11:07:35 Pacific
Subject: How to Replace path in registry
OS: win 98
CPU/Ram: 450/64
Comment:

I want to download a software through which i can make changes in "Regedit" file of windows98. By changes i mean i want to relpace the alphabets of entry in whole registry. For example if i have installed my all softwares in "D:\Program files" folder so in registry this path will be given to windows to access my software. Now if i rename folder "Program files" to a new name like "My softwares" this change has to be addressed in registry otherwise program will not run. So i need a software which gives the option of "Replace" or "Replace All" in registry.


Report Offensive Message For Removal


Response Number 1
Name: FJ
Date: July 23, 2004 at 12:53:03 Pacific
Reply: (edit)

If I understand you, there are no programs written to do what you want.

First of all, that is so much more complicated then you make it sound.

If you want to do something like that then you could possibly change the "Program Files" name to something else, as soon as you load the OS onto the hard drive. But then you have to tell every single program the new name when installing the individual programs.

Or you could start right now by creating a folder named "My softwares" or whatever you like, and then start reloading the programming into it.

To redirect Windows into looking for programming that is already installed in the manner in which you are suggesting would be a monumental effort in programming, and I doubt anyone has do it.

Good luck in your efforts and please post your finding, if you are successful.


Report Offensive Follow Up For Removal

Response Number 2
Name: moonnightingale
Date: July 23, 2004 at 13:30:23 Pacific
Reply: (edit)

Thanks FJ for ur concern and detailed answer i know it is very rare but still i hope to find this software


Report Offensive Follow Up For Removal

Response Number 3
Name: Derek
Date: July 23, 2004 at 13:52:38 Pacific
Reply: (edit)

I too know of no software.

I suppose you could just use regedit search (edit/Find) for c:\program files then change each entry manually, but I fear that "program files" is fundamental to the OS and there could be unforseen snags.

If you go this way I would definitely save or export your registry before you start.

I should think program files appears within many .ini files. Many of these would need changing too, otherwise they would keep restoring the registry entries.

Derek.W


Report Offensive Follow Up For Removal

Response Number 4
Name: pr3d
Date: July 23, 2004 at 15:12:50 Pacific
Reply: (edit)

What if you exprot the registry to a .reg file, open that file in a 32bit text editor and use the find-replace function in the text editor then save it again as a .reg and double click it.

I dont advise just going off and doing this with out making a 2 copies, 1 unchanged and the second all found and replaced.



Report Offensive Follow Up For Removal

Response Number 5
Name: pr3d
Date: July 23, 2004 at 15:47:54 Pacific
Reply: (edit)

replace "x:\path\"
with "z:\newpath\"

just incase your wondering.


Report Offensive Follow Up For Removal


Response Number 6
Name: pr3d
Date: July 23, 2004 at 18:07:12 Pacific
Reply: (edit)

if you tried this let me know if it worked


Report Offensive Follow Up For Removal

Response Number 7
Name: moonnightingale
Date: July 24, 2004 at 02:54:08 Pacific
Reply: (edit)

I will try and let u know thnaks


Report Offensive Follow Up For Removal

Response Number 8
Name: Bryco
Date: July 24, 2004 at 07:12:35 Pacific
Reply: (edit)

As a test I created a new key and a Path value in the registry for this make believe program.

I exported the key, modified the path statement, saved it and merged it back into the registry.

It did so successfully.

Do heed Derek's warning about the .ini files, the install logs and uninstall logs.

Before attempting to use Add/Remove to uninstall any of the moved files you will need to modify the path statements in each that are located within the program's folder.

As an example; below is the Uninstall log for a program AVIMGen program: (it's long)
%% PLEASE DO NOT MODIFY OR DELETE THIS FILE! %%
%% This file contains information about the installation of an application. %%
%% It will be used to automatically remove all application components from your computer if you choose to do so. %%


NOTE: Beginning of the bootstrapper section

CONFIG: Title: "AVIMGen 1"

ACTION: RegKey: "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion", "SharedDLLs"

ACTION: SystemFile: "C:\WINDOWS\SYSTEM\VB6STKIT.DLL"
(File currently on disk was already up to date)

ACTION: SystemFile: "C:\WINDOWS\SYSTEM\COMCAT.DLL"
(File currently on disk was already up to date)

ACTION: SystemFile: "C:\WINDOWS\SYSTEM\STDOLE2.TLB"
(File currently on disk was already up to date)

ACTION: SystemFile: "C:\WINDOWS\SYSTEM\ASYCFILT.DLL"
(File currently on disk was already up to date)

ACTION: SystemFile: "C:\WINDOWS\SYSTEM\OLEPRO32.DLL"
(File currently on disk was already up to date)

ACTION: SystemFile: "C:\WINDOWS\SYSTEM\OLEAUT32.DLL"
(File currently on disk was already up to date)

ACTION: SystemFile: "C:\WINDOWS\SYSTEM\MSVBVM60.DLL"
(File currently on disk was already up to date)

ACTION: DllSelfRegister: "C:\WINDOWS\SYSTEM\COMCAT.DLL"

ACTION: TLBRegister: "C:\WINDOWS\SYSTEM\STDOLE2.TLB"

ACTION: DllSelfRegister: "C:\WINDOWS\SYSTEM\OLEPRO32.DLL"

ACTION: DllSelfRegister: "C:\WINDOWS\SYSTEM\OLEAUT32.DLL"

ACTION: DllSelfRegister: "C:\WINDOWS\SYSTEM\MSVBVM60.DLL"

NOTE: End of the bootstrapper section

NOTE: Now spawning the main Setup program 'Setup1.exe'....

ACTION: CreateDir: "C:\Program Files\AVIMGen"

ACTION: CreateDir: "C:\WINDOWS\Start Menu\Programs\AVIMGen"

ACTION: PrivateFile: "C:\Program Files\AVIMGen\AVIMGen.HLP"
(File was not found or was an older version -- new file copied)

ACTION: PrivateFile: "C:\Program Files\AVIMGen\AVIMGen.GID"
(File was not found or was an older version -- new file copied)

ACTION: PrivateFile: "C:\Program Files\AVIMGen\dancingbaby.avi"
(File was not found or was an older version -- new file copied)

ACTION: PrivateFile: "C:\Program Files\AVIMGen\boxes.avi"
(File was not found or was an older version -- new file copied)

ACTION: SharedFile: "C:\WINDOWS\SYSTEM\MSCOMCTL.OCX"
(File currently on disk was already up to date)

ACTION: SharedFile: "C:\WINDOWS\SYSTEM\Comdlg32.ocx"
(File currently on disk was already up to date)

ACTION: SharedFile: "C:\WINDOWS\SYSTEM\MSIMG32.DLL"
(File currently on disk was already up to date)

ACTION: PrivateFile: "C:\Program Files\AVIMGen\AVIMGen.exe"
(File was not found or was an older version -- new file copied)

ACTION: DllSelfRegister: "C:\WINDOWS\SYSTEM\MSCOMCTL.OCX"

ACTION: DllSelfRegister: "C:\WINDOWS\SYSTEM\Comdlg32.ocx"

ACTION: ShellLink: "AVIMGen", "AVIMGen"

ACTION: ShellLink: "AVIMGen", "AVIMGen Help"

ACTION: RegKey: "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion", "App Paths\AVIMGen.exe"

ACTION: RegValue: "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\AVIMGen.exe", ""


You can see that there are many references to the C:\Program paths and many to shared files.

In trying to run one of the moved programs you may have to reregister some of the .dll files too.

Do look into one of the programs you are wanting to move to see what it entails. Not all programs have an install.log or the others.

PC Magazine's program COA2 performs the function you have requested but will only do one program at a time.

I got my copy of it before PC Mag went to a "Pay for downloads" site but their download prices are quite reasonable.

It is my speculation that your task is going to cause more problems that you can imagine but...

Bryan


Report Offensive Follow Up For Removal

Response Number 9
Name: Derek
Date: July 24, 2004 at 09:34:10 Pacific
Reply: (edit)

I agree with Bryco that unless you can find some program (never run into one) then this could cause a lot of problems. As Bryco said, you have to be sure that your programs will also uninstall from the new folder.

Can I ask why you wish to do this? I just wondered if there was any alternative way to deal with what you are trying to achieve - we may be able to suggest something neater and safer.

Derek.W


Report Offensive Follow Up For Removal

Response Number 10
Name: pr3d
Date: July 24, 2004 at 11:57:21 Pacific
Reply: (edit)

moon I say go for it if throw caution onto the wind and post te results alot of that cut and past log shows no dll or ocx in the c:\progra~1 true you might not be able to uninstall using the nice add/remove but really how gives cow here, in my best starski voice "doit" these guys no are treating you like your a user on their administraed network, it is good to be cautious but thats why your gona make the back up, test it out ill try it over on my junk box too maybe we can combine minds here, who knows make up some software that would do this... we need results!!!


Report Offensive Follow Up For Removal

Response Number 11
Name: Derek
Date: July 24, 2004 at 13:43:46 Pacific
Reply: (edit)

prd3

It think it goes like this. Sure, many of us have learned a lot by experiment (with good and bad results). In the end a poster can do what he/she likes.

Having said that, when I am on here I try to avoid suggesting things that might wreck someone's machine. If there is some alternative approach I will seek it.

Happy to accept that you might have a different view.

Derek.W


Report Offensive Follow Up For Removal

Response Number 12
Name: pr3d
Date: July 24, 2004 at 14:53:40 Pacific
Reply: (edit)

Sorry Derek, I agree with you total but I can only assume that this person asking has some enough knowledge about their system to try such a thing, please note that I did advise the poster to make a back-up incase of some malfunction, that being said:


Two roads diverged in a yellow wood,
And sorry I could not travel both
And be one traveler, long I stood
And looked down one as far as I could
To where it bent in the undergrowth;

Then took the other, as just as fair,
And having perhaps the better claim,
Because it was grassy and wanted wear;
Though as for that the passing there
Had worn them really about the same,

And both that morning equally lay
In leaves no step had trodden black.
Oh, I kept the first for another day!
Yet knowing how way leads on to way,
I doubted if I should ever come back.

I shall be telling this with a sigh
Somewhere ages and ages hence:
Two roads diverged in a wood, and I-
I took the one less traveled by,
And that has made all the difference.

~*~ The Road Not Taken ~*~
by Robert Frost


Report Offensive Follow Up For Removal

Response Number 13
Name: Derek
Date: July 24, 2004 at 15:04:26 Pacific
Reply: (edit)

pr3d
Fair enough - liked the poem! I do that on my computer all the time LOL....

Derek.W


Report Offensive Follow Up For Removal

Response Number 14
Name: pr3d
Date: July 24, 2004 at 15:19:17 Pacific
Reply: (edit)

Yeah me too, I love experiments, surprisingly alot of the time the results are worth it. My computers have been science monkeys from the first one I turned on, always there only to awnser my "what if?'s"


Report Offensive Follow Up For Removal

Response Number 15
Name: Bryco
Date: July 24, 2004 at 17:21:39 Pacific
Reply: (edit)

My child needed more room in the driveway to play so I backed my car out onto the main road. It worked! She had more room to play.

An hour later the street sweeper came by and sideswiped my car and I got a ticket for parking there.

My child did have more room to play though.

My point is that there will be consequences for the actions taken.

(I think Homeflash said) "If it was easy we'd all be doing it."

There is always "scanreg /restore" to fall back upon.

Some time ago I had installed a second hard drive for the first time. As a result all programs that required the CD to run no longer functioned because the drive letter that the program was installed from was now pushed out by one letter.

I manually used Find in regedit to locate and change all occurances of D:\ to E:\.

Some of the CD mounted applications worked but many still did not. I kept getting "insert CD in CD ROM drive letter D:" that was the old letter.
I had to uninstall and then reinstall them from the new drive letter to make them work.

Bryan
(Of course I made up the story about the car)


Report Offensive Follow Up For Removal

Response Number 16
Name: pr3d
Date: July 24, 2004 at 22:40:34 Pacific
Reply: (edit)

of course you did and its computer related :p

"So i need a software which gives the option of "Replace" or "Replace All" in registry."

MOON DO IT!!!!



Report Offensive Follow Up For Removal

Response Number 17
Name: moonnightingale
Date: July 25, 2004 at 14:10:17 Pacific
Reply: (edit)

Dear Frd,
You told me to use 32 Bit Text editor. I downloaded a 32 bit text editor but when i tried to open registry file i got the message

" Regedit has a type indicating to be binary, which will not load or edit correctly"

and when i opened it, it showed me same machine language as normal edit command of windows does.
kindly also explain me what r these 32 bit files, binary files and our normal word files. thanks.

and "i m doing it just for sake of knowldge" thanks to all ppl for their knowldge


Report Offensive Follow Up For Removal

Response Number 18
Name: Derek
Date: July 25, 2004 at 14:41:54 Pacific
Reply: (edit)

It is not uncommon to find a completely different approach to the "ultimate aim". If you just fancy a different name instead of Program Files then fine. Everyone to his own.

Otherwise there is always some possibility of approaching the "real aim" behind this in a "totally different way". That is why I asked why you feel the need to do this.

If it's personal or a secret then that's fine by me, we'll keep persuing it along the more difficult lines of registry editing and so forth.

Derek.W


Report Offensive Follow Up For Removal

Response Number 19
Name: Bryco
Date: July 25, 2004 at 18:06:43 Pacific
Reply: (edit)

I was recently introduced to EditPadLite. It opens my 12.3Mb .reg file just fine. It has Find & Replace and Replace All features. It is fast too.

Do read the information during the installation to be sure to select the things you want from it.

I would also recommend that you browse many of the items it is going to 'replace' before you start replacing anything just to make sure that you get what you are wanting out of this exercise.

Regards,
Bryan


Report Offensive Follow Up For Removal

Response Number 20
Name: Bryco
Date: July 25, 2004 at 18:18:13 Pacific
Reply: (edit)

Moon,

If I am re-reading your last post correctly then you are using the wrong file.

Go to Start, Run, regedit and Click Ok.

"My Computer" will be already selected/highlighted.
Go to Registry, Export Registry File.
Save it to your Desktop for easy usage with the name "July2504" or something similar.
The file will have a .reg extension. (I sure hope you have your machine set to show extensions)

Open EditPad Lite and go to File, Open. Browse to your Desktop and the July2504.reg file and select it.

Do your thing to it.

Go to File, Save As and save it as July2504R.reg so you know it is the new one.

Now, with your bells in your hand right click on the July2504R.reg, select Merge and then answer Yes to allow it to merge into your registry.

Restart the PC.

If it won't start (for some reason?) then restart it again but hold down the Ctrl key on the POST screen until the Startup menu appears. Then select Command prompt only.

At the C:> prompt type:
scanreg /restore
Hit Enter.
Select the registry file named after the same date that you are doing this.
That file was the one that started your PC the first time of this day.

Best wishes,
Bryan


Report Offensive Follow Up For Removal

Response Number 21
Name: pr3d
Date: July 25, 2004 at 19:30:53 Pacific
Reply: (edit)

<u>Moon</u>

Click Start -> Run -> RegEdit:

When RegEdit opens click on Regestry -> Export Registry File. Save it as moon.reg on your desktop.

<u>Next</u>

Click start -> Run -> Wordpad:

When word pad opens DRAG AND DROP! moon.reg into the great big white space.

Now on the tool bar across the top of Wordpad click on Edit and scroll down to Replace, click on that, when the box opens check the Match whole word only option and then in the Find field enter C:\Program Files and in the Replace field enter C:\Example baring in mind your using the drive letters and file names on your machine not in this example, then click Replace all.

NOT DONE YET there is a short name for program files and you want to change that too, so in the find field type C:\Progra~1 and in the Replace field enter C:\Example. Now you can click on File and select Save As, name it moon.reg as a Unicode format, then you may double click on moon.reg.

BUT DONT CLICK IT UNTILL YOU HAVE UNDERSTOOD THE SCANREG /RESTORE INSTRUCTIONS

ok now, DO IT!


Report Offensive Follow Up For Removal

Response Number 22
Name: Bryco
Date: July 27, 2004 at 11:30:38 Pacific
Reply: (edit)

It has been two days since we have heard from Moon.

Was the experiment a failure by evidence of Moon's absence?

Bryan


Report Offensive Follow Up For Removal

Response Number 23
Name: moonnightingale
Date: July 29, 2004 at 11:41:52 Pacific
Reply: (edit)

I m safe Dear i was away thanks for ur help


Report Offensive Follow Up For Removal

Response Number 24
Name: Bryco
Date: July 29, 2004 at 15:49:32 Pacific
Reply: (edit)

Moon,

Thank you for posting back.

How did the experiment go? Did it work as you had hoped?

Regards,
Bryan


Report Offensive Follow Up For Removal






Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Windows 95/98 Forum Home








Do you have your own blog?

Yes
No
I did before
I will soon


View Results

Poll Finishes In 4 Days.
Discuss in The Lounge
Poll History




Data Recovery Software