简体   繁体   English

如何将制表符分隔的文本文件导入Excel?

[英]How to import Tab delimited Text files into Excel?

I have multiple text files (.txt) with Tab delimited in a folder. 我有多个文本文件(.txt)与文件夹中的制表符分隔。 The text file contains first line as column headings. 文本文件包含第一行作为列标题。 I have one pre defined excel template with column names. 我有一个带有列名的预定义excel模板。 I am able to import the text files into excel template. 我可以将文本文件导入excel模板。 But, what i need to do is how to delimit if the column heading not match with Excel column headings Through VBA. 但是,我需要做的是如何划分列标题是否与Excel列标题通过VBA不匹配。 Thanks in advance for any help ..... 在此先感谢任何帮助.....

It's possible to do it in Excel itself, in Office 2010 its in the Data tab > Text to columns. 可以在Excel本身中执行此操作,在Office 2010中,可以在“数据”选项卡>“文本到列”中执行此操作。 There you can select that its delimited by tabs, and there you go, your data should be columnised 在那里你可以选择它由制表符分隔,然后你去,你的数据应该列为列

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM