# Help .exe files changed to .lnk files



## canadacowboy (Apr 29, 2007)

I had a trojan and have it cleaned out, I've tried to redit the registry, but the shortcuts are still .lnk files. Is there some way to get the shortcuts to work again or do I have to reformat? I've even tried to make new shortcuts but they wouldn't go.
Thanks
Bill


----------



## Elvandil (Aug 1, 2003)

Shortcuts are supposed to be .lnk files. The ending is usually invisible. 

What happens when you click a shortcut?


----------



## canadacowboy (Apr 29, 2007)

Thanks for answering, I get "This file does not have a program associated with it for performing the action. Create and association in the Folder Options Control Panel.


----------



## Elvandil (Aug 1, 2003)

OK. But what about your title? Have exe's changed to lnk's?


----------



## Elvandil (Aug 1, 2003)

To fix the lnk association, copy the text between the lines, paste it in a Notepad window, save as "lnk.reg" (no quotes). Then, right-click the reg file and merge it with your registry.

-----------------------------------------------------------------------------------------------
Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\.lnk]
@="lnkfile"

[HKEY_CLASSES_ROOT\.lnk\ShellEx]

[HKEY_CLASSES_ROOT\.lnk\ShellEx\{000214EE-0000-0000-C000-000000000046}]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\.lnk\ShellEx\{000214F9-0000-0000-C000-000000000046}]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\.lnk\ShellEx\{00021500-0000-0000-C000-000000000046}]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\.lnk\ShellEx\{BB2E617C-0920-11d1-9A0B-00C04FC2D6C1}]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\.lnk\ShellNew]
"Command"="rundll32.exe appwiz.cpl,NewLinkHere %1"

[HKEY_CLASSES_ROOT\lnkfile]
@="Shortcut"
"EditFlags"=dword:00000001
"IsShortcut"=""
"NeverShowExt"=""

[HKEY_CLASSES_ROOT\lnkfile\CLSID]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\lnkfile\shellex]

[HKEY_CLASSES_ROOT\lnkfile\shellex\ContextMenuHandlers]

[HKEY_CLASSES_ROOT\lnkfile\shellex\ContextMenuHandlers\Offline Files]
@="{750fdf0e-2a26-11d1-a3ea-080036587f03}"

[HKEY_CLASSES_ROOT\lnkfile\shellex\ContextMenuHandlers\{00021401-0000-0000-C000-000000000046}]

[HKEY_CLASSES_ROOT\lnkfile\shellex\DropHandler]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\lnkfile\shellex\IconHandler]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\lnkfile\shellex\PropertySheetHandlers]

[HKEY_CLASSES_ROOT\lnkfile\shellex\PropertySheetHandlers\ShimLayer Property Page]
@="{513D916F-2A8E-4F51-AEAB-0CBC76FB1AF8}"

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}]
@="Shortcut"

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}\InProcServer32]
@="shell32.dll"
"ThreadingModel"="Apartment"

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}\PersistentAddinsRegistered]

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}\PersistentAddinsRegistered\{89BCB740-6119-101A-BCB7-00DD010655AF}]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}\PersistentHandler]
@="{00021401-0000-0000-C000-000000000046}"

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}\ProgID]
@="lnkfile"

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}\shellex]

[HKEY_CLASSES_ROOT\CLSID\{00021401-0000-0000-C000-000000000046}\shellex\MayChangeDefaultMenu]

--------------------------------------------------------------------------------------------------------


----------



## canadacowboy (Apr 29, 2007)

The programs are still .exe files


----------



## Elvandil (Aug 1, 2003)

What programs are still exe files? You said that your shortcuts are .lnk files which is what they are supposed to be. You didn't mention exe files except in your title.

Which files are exe files?

Did you try the registry merger? The lnk files should no longer show their ending after the merger, or you may need to reboot for the changes to occur.


----------



## canadacowboy (Apr 29, 2007)

Sorry I'm lost how do I merge into reg


----------



## canadacowboy (Apr 29, 2007)

The .exe files are in the program folders, can't change the icons or get the shortcut to work.


----------



## Elvandil (Aug 1, 2003)

After creating the file with Notepad, right-click the reg file and choose "Merge".


----------



## canadacowboy (Apr 29, 2007)

The notepad will not open


----------



## Elvandil (Aug 1, 2003)

Probably because the shortcut doesn't work. Try starting it directly by opening up your Windows folder and looking for notepad.exe. Double-click it and see if it will open.

If it does, paste the text between the lines above into an empty Notepad window and save it to your desktop as lnk.reg

The lnk.reg file should have a blue registry icon. Right-click it and choose "Merge" from the menu.


----------



## canadacowboy (Apr 29, 2007)

Where do I find the reg file


----------



## Elvandil (Aug 1, 2003)

Please read post #5 above carefully.


----------



## canadacowboy (Apr 29, 2007)

I have all the info copied between the lines and pasted it to the notepad which I saved to desktop as link.reg. I right clicked on it and didn't see any merge. Hate to be such a dumb ###, but what am I'm missing?


----------



## Elvandil (Aug 1, 2003)

Just the text between the lines and not the lines themselves, right? Including "Windows Registry Editor Version 5.00"? Did the resulting file have a blue icon with little blocks?


----------



## Elvandil (Aug 1, 2003)

Maybe I assumed incorrectly. Is this Windows XP?


----------



## canadacowboy (Apr 29, 2007)

Just between the lines, and its green not blue but green text. It starts like so "Windows Registry Editor Version 5.00"


----------



## Elvandil (Aug 1, 2003)

OK. Is the icon a Notepad icon or something else, with little blocks?

Try double-clicking the reg file to see if it will merge.


----------



## canadacowboy (Apr 29, 2007)

Windows XP SP2 Home


----------



## Elvandil (Aug 1, 2003)

If it's really a .reg file, it should have "Merge" in the right-click menu. If not, try merging it by double-clicking.

If that doesn't work, you may have more file association problems than just the lnk files.


----------



## canadacowboy (Apr 29, 2007)

I double click on it and the notepad opens up, right click I don't find no merge.


----------



## Elvandil (Aug 1, 2003)

OK. I suspect that you have common file type endings hidden and you really saved that file as a text file.

Go to Control Panel, Folder Options, View tab.

Uncheck the box that says to hide file endings for known file types. Apply.

Then, go back to your reg file. It will now be named link.reg.txt

Rename it so that it is link.reg

You will get a warning about changing file endings, but that is OK. Then, Merge should be in the menu.


----------



## canadacowboy (Apr 29, 2007)

Earlier I tried to change the Icon on outlook express and now all the shortcuts are outlook icons.


----------



## canadacowboy (Apr 29, 2007)

I get the same thing nothing to associate with.


----------



## Elvandil (Aug 1, 2003)

When do you get the "Nothing to associate with"?

Go to Start > Run, and type:

control <enter>

That should get you into the Control Panel. Then do the Folder Options thing I described above.


----------



## canadacowboy (Apr 29, 2007)

This file does not have a program associated with it for performing the action. Create and association in the Folder Options Control Panel.


----------



## Elvandil (Aug 1, 2003)

Which file? Did you run control and get into the Control Panel?


----------



## canadacowboy (Apr 29, 2007)

Yes I did its unchecked and and the notepad was changed to lnk.reg


----------



## Elvandil (Aug 1, 2003)

OK. Then did Merge apear in the right-click menu?


----------



## canadacowboy (Apr 29, 2007)

Yes it did, but still get the same error message.


----------



## Elvandil (Aug 1, 2003)

It sounds like more file associations are messed up.

Did the icon for the reg file change to the little bluish blocks I mentioned before?

Can you double-click the reg file?


----------



## canadacowboy (Apr 29, 2007)

No blue blocks, its a square with the block inside with three colored inside it. I can double click but get the same error I get when I click merge.


----------



## Elvandil (Aug 1, 2003)

OK. The reg file association is messed up, too. There may be more. Do you want to go back to a restore point or just fix the lnk files?

If you want to fix the lnk files, open up My Computer and click on C:.

Put your reg file in there. Was it link.reg?

Then, go to Start > Run and type:

regedit C:\link.reg

See if you can merge it that way.


----------



## canadacowboy (Apr 29, 2007)

I can't do a restore for some reason there is no restore point? I've tried that earlier. Let me try the other you suggest and see what happens. How do you straightern out the file associations?


----------



## Elvandil (Aug 1, 2003)

Let's do the lnk one first and then take it from there.


----------



## canadacowboy (Apr 29, 2007)

I went the run and it asked if I wanted to change the reg and I clicked yes. Don't look like anything changed. Is ii supposed to be link.reg or lnk.reg?


----------



## canadacowboy (Apr 29, 2007)

It is no longer on my desktop


----------



## Elvandil (Aug 1, 2003)

Whatever you named it.
If you didn't use the name you gave it, try again with your name. It may take a reboot for the files to change to their normal appearance. But try a shortcut anyway to see what happens.


----------



## canadacowboy (Apr 29, 2007)

I clicked on a shortcut and it seems to come up alright, but the Icons didn't change booting up now hope its working. Seems like it is going to take awhile to reboot.


----------



## canadacowboy (Apr 29, 2007)

OK its booted up and the icons are back and they seem to be working correctly.


----------



## Elvandil (Aug 1, 2003)

There's no telling how much damage was done in the registry. Things there are interconnected and an error can propagate to affect other things.

Depending how much damage there is, and also whether the file association for batch files has been damaged, you may be able to restore the default associations that XP shipped with by unzipping the attached file and running the batch file inside.

This file is from Doug Knox' site.


----------



## Elvandil (Aug 1, 2003)

canadacowboy said:


> OK its booted up and the icons are back and they seem to be working correctly.


OK. Good work. Anything else we need to fix?

To fix the file association for reg files, click on one. When it asks what program to use (after turning down the internet offer), direct it to regedit.exe, probably in the Windows folder. Be sure the box that says to always open this type of file with this program (at the bottom) is checked.

If you think we are done, you can mark the thread "solved" using the Thread Tools above.

If there is more you would like to do, fire away!


----------



## canadacowboy (Apr 29, 2007)

If this doesn't pretty well clean it up, does that me reformant? I sure appreciate your help I wll donate, sure glad there are individuals like you that take the time and patience to work with people like me.
The bat file will not open I get a icon change


----------



## Elvandil (Aug 1, 2003)

If you have the XP CD, you can run a repair installation to see if that will fix things. A repair installation lets you keep your files and programs so you don't need to start from scratch.

But, a repair installation sometimes doesn't fix all problems, either. It's worth a try.

You could just run for a while and see how things go. If there are lots of problems, then a repair might be a good starting place.


----------



## Elvandil (Aug 1, 2003)

Here's another idea. If the file associations seem to be the major or only problem, fix the reg association according to my directions above so that the Merge command works.

Then, you can go to this page and download fixes for any other file associations you are having problems with. They are mostly reg files, so you would need to get those working properly first.


----------



## canadacowboy (Apr 29, 2007)

Thank You, I've had problems with repair before but I'll give it a shot. I'll kind of work with this for a day or two and see what happens and see how it works.
Thanks again
Bill


----------



## Elvandil (Aug 1, 2003)

Good luck.


----------



## canadacowboy (Apr 29, 2007)

Thank You


----------



## Elvandil (Aug 1, 2003)

Hey, I live so far north, I'm almost Canadian!


----------

