小刀人
-No business too small, no problem too big.
<2007年11月>
28293031123
45678910
11121314151617
18192021222324
2526272829301
2345678
公告
  • Learn,Think,and Imagine...

    正在看的书:

    点击发送消息给我

留言簿(6)

随笔分类

随笔档案

文章档案

相册

CSDN

VC知识库

开发站点

技术blog

搜索

最新评论

  • 1. purchase xanax
  • Some editors are failed writers, but so are most writers.
  • --purchase xanax
  • 2. neomwvbl
  • --neomwvbl
  • 3. order xanax
  • Think of yourself as an incandescent power, illuminated and perhaps forever talked to by God and his messengers.
  • --order xanax
  • 4. cialis for
  • It is your work in life that is the ultimate seduction.
  • --cialis for
  • 5. ffysegxg
  • --ffysegxg
  • 6. ammonation
  • God is a comedian playing to an audience too afraid to laugh.
  • --ammonation
  • 7. dyed
  • That would be a good thing for them to cut on my tombstone: Wherever she went, including here, it was against her better judgment.
  • --dyed
  • 8. ebullioscopic
  • We are made to persist. That's how we find out who we are.
  • --ebullioscopic
  • 9. keppra
  • They are ill discoverers that think there is no land, when they can see nothing but sea.
  • --keppra
  • 10. ampicillin
  • Any transition serious enough to alter your definition of self will require not just small adjustments in your way of living and thinking but a full-on metamorphosis.
  • --ampicillin
  • 11. reglan
  • The most erroneous stories are those we think we know best - and therefore never scrutinize or question.
  • --reglan
  • 12. oryxbxoc
  • --oryxbxoc
  • 13. linnaeite
  • In America, they want you to accomplish these great feats, to pull off these David Copperfield-type stunts. You want me to be great, but you don't ever want me to say I'm great?
  • --linnaeite
  • 14. humungous
  • --humungous
  • 15. doxycycline hyclate
  • There are sadistic scientists who hurry to hunt down errors instead of establishing the truth.
  • --doxycycline hyclate
  • 16. cephalexin 500mg hypermedia argyrophil
  • It is not enough to aim; you must hit.
  • --cephalexin 500mg hypermedia argyrophil
  • 17. female viagra
  • Good judgment comes from experience, and experience comes from bad judgment.
  • --female viagra
  • 18. sjkovbbg
  • --sjkovbbg
  • 19. datapath
  • We don't know a millionth of one percent about anything.
  • --datapath
  • 20. verticilliose
  • All truth passes through three stages. First, it is ridiculed. Second, it is violently opposed. Third, it is accepted as being self-evident.
  • --verticilliose

阅读排行榜

评论排行榜

 
VC知识库BLOG   首页  新随笔  联系  聚合  登录 
  随笔-23 文章-0 评论-184 Trackbacks-0

上次的实现只是做到了全文导入Excel中,而且文本文件.txt为扩展名的,只能以制表符分列,用逗号不可以。(CSV文件都用逗号,当然没有问题。)
这两天没事的时候,我又加入了些功能:可以导入指定行,进一步完善了。
例如,如下的文本文件(.txt):

文本中的逗号可以是全角或半角。可以用如下格式导入Excel:

做这些工作需要一个中间文本文件interfile.txt。工具界面如下:


看到前面的行号了吗?这是我在文本框里加入的,源文本文件没有变化(数据保持干净)。中间文本文件interfile.txt里有前面的行号,这样你可以在Excel中看到你导入了源文本的哪些行。
源代码(VB6.0)下载地址:http://blog.vckbase.com/Files/zhaotide/texttoxlsa.rar

posted on 2005-04-09 09:11 小刀人 阅读(14767) 评论(19)  编辑 收藏
Comments
  • # 老大,EXCEL本身菜单就可以导入的吧。
    Diviner
    Posted @ 2005-04-09 09:14
    rt
  • # re: 将文本文件(以逗号或制表符任意分列)导入Excel(更新版)
    小刀人
    Posted @ 2005-04-09 09:15
    分列是个问题
  • # 分列的时候可以选择以宽度或者分隔字符的呀。以前我最喜欢把d2的TXT文件导入了。
    Diviner
    Posted @ 2005-04-09 09:32
    rt
  • # 呵呵,just for fun!
    小刀人
    Posted @ 2005-04-09 12:00
    还有指定行的问题啊!
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    yitanglu
    Posted @ 2005-04-25 11:35
    用alt + printscreen可以拷贝当前画面
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    okmm2005
    Posted @ 2005-07-06 16:31
    小刀大哥:有没有原程序啊?
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    小刀人
    Posted @ 2005-07-07 17:36
    你如果真的需要告诉我你的邮箱,给你发去。
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    xieyi
    Posted @ 2005-08-26 10:06
    请问如何将指定列导入到指定位置?希望有原码

    谢谢
    油箱:xie6525@uidaho.edu

  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    末末姜
    Posted @ 2007-04-21 10:04
    我这里急须一个程序,把大量的文本转换成EXCEL,
    看了你的程序觉得不错,可惜我不会批量转换,不知能不能改进一下?
    另外我的文件好象不是以制表符分隔的,所以不能分列,还望指教啊。。。
    邮箱:lingjiao0710@163.com
    QQ:51503641
    谢谢~!!
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    海啸
    Posted @ 2007-05-10 17:02
    以空格为分隔符的可以不?还有把分列项设成文本功能还没有啊!再加个批量功能就完善了!我的QQ:116446203 邮箱:smalt818@126.com
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    lwliu
    Posted @ 2007-07-10 14:13
    你好帮忙把原程序给我发一个,谢谢
    lwliu2004@yahoo.com.cn
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    次搜
    Posted @ 2007-07-25 23:28
    给我发个源程序,急需要,非常感谢
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    小林
    Posted @ 2007-07-25 23:28
    给我发个源程序,急需要,非常感谢,邮箱dreamlin16@163.com
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    芝芝
    Posted @ 2007-07-31 16:07
     给我发个源程序,急需要,非常感谢,邮箱michael_chenzy@163.com
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    天马行空
    Posted @ 2007-08-05 09:06
    不错,收下了
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    eco
    Posted @ 2007-11-09 10:32
    我也求一个源程序,急切的想学习下。bgmqj@hotmail.com,谢谢
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    eco
    Posted @ 2007-11-09 10:39
    哦,原来已经放上去了,收下,3q
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    gong
    Posted @ 2009-05-09 08:01
    朋友你好,我想咨询一下,怎么将两个.txt文档导入到一个Excel表中,这个表有两个sheet页,分别存放两个文档的内容,请赐教 非常感谢! 我的邮箱:heiyanzi123@126.com
  • # re: 将文本文件(以逗号或制表符任意分列)全文或指定行导入Excel(更新版)
    chip
    Posted @ 2009-05-15 16:27
    朋友,我想看看您的原代码,麻烦您给发下,谢谢!~~~~
    hjp49116198@163.com
标题  
姓名  
主页
验证码 *
内容   
  登录  使用高级评论  Top
[使用Ctrl+Enter键可以直接提交]