Wednesday, March 09, 2005

Changing default text import origin type in Excel

Importing iButton temperature data from text files into Excel is helped by having the text imported in the proper format for your later usage. For some reason, my version of Excel wanted to import text files using a Japanese origin, which gave me date formats and degree signs where I didn't want them.

I wanted my text to come in as Unicode, and since I import a lot of files, I wanted this as the default to save a step or two when importing. You'll notice in the picture below that when you choose Unicode, it shows a value just to the left (65001). Write this number down, you'll need it in a second.

You can change the default choice by running regedit from the Program>Run menu item. Once in the Registery Editor, navigate to HKEY_CURRENT_USER>Software>Microsoft>Office>11.0>Excel>Options
Once here, you'll see a few registry entries for Excel 2003.
Right click in the right-hand window and choose New>DWORD
Call the new DWORD item DefaultCPG and hit enter.
Then right click on DefaultCPG and choose Modify.
Set the Base to Decimal, and enter the decimal value for Unicode UTF-8 (65001 in this case), then hit OK.