Link to home
Start Free TrialLog in
Avatar of onaled777
onaled777Flag for United States of America

asked on

Aumatic data entry in Excel for Key Value Pairs

I have a txt file with entries with lines in the format:

Name=Value
eg.
error.booking.wrong-cc=You entered an invalid credit card number. Please enter a valid one.


It was nearly four hundred lines like this and I was hoping there was a way to automate the entry of this data into a two column excel spreadsheet. There the equal sign is would begin the second column.

Does anyone know how this could be done?
Avatar of Michael
Michael
Flag of Belgium image

Hi,

In Excel you can import the text file and then use the 'Text to columns'  function:

1. On the Data tab
2. Click on Get External Data from Text
3. Select your text file
4. Select Delimited, Next
5. Deselect all other options and select 'Other' and type '=' (without the quotes)
6. Click Finish

Nou you should have your data split in two columns.
Avatar of byundt
If your data is already in Excel, then you can split it on the equals sign using the Data...Text to Columns menu item. You want to specify Delimited in the first step of the wizard and choose Other with = in the second step.
ASKER CERTIFIED SOLUTION
Avatar of Naresh Patel
Naresh Patel
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial