6

When trying to edit .html files on Windows XP, they open up in MS Word. Is there any reason that this is the default rather than something that is more lightweight and only deals with plain text and doesn't insert any sort of formatting/complex objects (such as Notepad)? Does Word really provide any extra benefit to editing .html files?

On a related note - how can this setting be changed to use something like Notepad, Wordpad, Notepad++, etc?

2 Answers 2

7

Windows itself doesn't set that association, Office does when it's installed. The reason, I suppose, is that Microsoft intended to make it so that editing HTML files was easier for 'regular people', and Word can (sort of) achieve that.

To change the 'Edit' association, you'll need to go into Windows's file types settings:

  1. Open any folder in Explorer (My Computer, for example)
  2. Go to Tools > Folder Options
  3. Go to the File Types tab
  4. Scroll to and then highlight HTM and/or HTML (you can just tap H on the keyboard probably)
  5. Click the Advanced button
  6. In the Edit File Type window, you will see 'Edit' listed under actions; make sure this is highlighted, and then click the Edit button

    (added). If 'edit' is not listed, then add it via the new button. 'edit', no caps.

  7. In the action editing window, first untick 'Use DDE'
  8. Then, in the 'Application used to perform action' field, change the application path to the application you want to use. Leave the %1 at the end alone. So, for example, to change it to Notepad, you can do: "C:\Windows\notepad.exe" %1
  9. Click OK, OK, OK
2
  • 5
    +1 I would suggest Notepad++ over Notepad for editing html files.
    – Ganesh R.
    Oct 26, 2011 at 6:10
  • 1
    @GaneshR. I would too, but Notepad is at least installed on any Windows default installation, and works as an HTML editor. I'm sure lots of people have their own preferred text file editor, though. Feb 5, 2013 at 18:44
5

This doesn't work in Windows 7 because there is no longer a File Types tab in the Folder Options. You can change the default program through the control panel, but not any of the other context menu options, unless you edit registry keys.

The Microsoft Approved way to do this is (and should also be in Windows XP):

  1. Open Internet Explorer
  2. Type Alt+T, and select Internet Options from the menu.
  3. Select the Programs tab
  4. Select from the dropdown "HTML editing", change this from Microsoft Word to another editor.
4
  • Thank you so much! That was very quick and simple. And yeah, though the original question is for Windows XP, this question is the top hit for the problem on Google - even if you are on Windows 7. So, this is answer is very welcome and has to be a full-fledged editable answer not a tiny locked comment @Ramhound
    – ADTC
    Jul 15, 2015 at 8:56
  • @Ramhound As you say. In any case, this answer is also valid for Windows XP. In fact it's valid for any Windows version that has "Internet Options" dialog in Control Panel. The answer is good in that regard. I'd argue better than the XP-only answer.
    – ADTC
    Jul 15, 2015 at 13:47
  • 1
    @ADTC - Sure. Original comment deleted to avoid being pinged again in 2 years.
    – Ramhound
    Jul 15, 2015 at 13:58
  • Jesus, the "Microsoft Approved" way is such a bad way ot setting it... You can't add your own programs, only choose from the ones offered, none of which I like!
    – jurchiks
    Apr 25, 2016 at 13:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.