如何将复杂的文本文件导入到ms访问中 [英] how to import complex text file into ms access

查看:82
本文介绍了如何将复杂的文本文件导入到ms访问中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只需要样品,附加信息,参考,分析物,%和缩放参考。


请参阅下面的文本文件示例,

-----------------------------------------------


方法:1金属模式样本:A46731 8/1/13 6:57:04 PM

附加信息:C4027

持续时间:5

好​​匹配

参考:Inco 718

差异:23.60

筛选方法:Ni Chem 1

Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W

%0.89 18.68 0.07 18.37 0.33 48.06 0.00> 5.38 3.03 0.45

STD 0.17 0.32 0.14 0.35 0.13 0.37 0.093 0.07 0.079 0.12

等级:Inconel 718

Scaling Ref。 :Inconel 718

缩放方法:Ni ID


方法:1金属模式样本:A46731 8/1/13 6:57:16 PM

其他信息:C4027

持续时间:5

好​​匹配

参考:Inco 718

差异:29.55

筛选方法:Ni Chem 1

Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W

%1.18 18.43< 0.04 18.90 0.18 47.89 0.00> 5.48 3.13 0.31

STD 0.15 0.28 0.12 0.31 0.11 0.32 0.074 0.06 0.069 0.093

等级:Inconel 718

Scaling Ref 。 :Inconel 718

缩放方法:Ni ID


方法:1金属模式样本:A46731 8/1/13 6:57:28 PM

其他信息:C4027

持续时间:5

好​​匹配

参考:Inco 718

差异:33.03

筛选方法:Ni Chem 1

Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W

%1.13 19.02 0.00 18.44 0.29 48.44 0.00> 5.34 2.89 0.42

STD 0.15 0.28 0.11 0.3 0.11 0.32 0.07 0.059 0.066 0.096

等级:Inconel 718

Scaling Ref。 :Inconel 718

缩放方法:Ni ID


方法:1金属模式样本:A46731 8/1/13 6:57:41 PM

其他信息:C4027

持续时间:5

好​​匹配

参考:Inco 718

差异:27.10

筛选方法:Ni Chem 1

Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W

%1.08 18.26 0.08 18.54 0.32 48.71 0.00> 5.37 2.88 0.34

STD 0.14 0.26 0.11 0.28 0.1 0.3 0.072 0.056 0.061 0.086

等级:Inconel 718

Scaling Ref。 :Inconel 718

缩放方法:Ni ID


---------------------- -------------------------------

感谢您的帮助

I only need "sample, additional info, reference, analyte, % and Scaling Ref."

see below for example of the text file,
-----------------------------------------------

Method: 1 Metal Mode Sample: A46731 8/1/13 6:57:04 PM
Additional info: C4027
Duration: 5
Good Match
Reference: Inco 718
Difference: 23.60
Screening Method:Ni Chem 1
Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W
% 0.89 18.68 0.07 18.37 0.33 48.06 0.00 >5.38 3.03 0.45
STD 0.17 0.32 0.14 0.35 0.13 0.37 0.093 0.07 0.079 0.12
Grades: Inconel 718
Scaling Ref. : Inconel 718
Scaling Method: Ni ID

Method: 1 Metal Mode Sample: A46731 8/1/13 6:57:16 PM
Additional info: C4027
Duration: 5
Good Match
Reference: Inco 718
Difference: 29.55
Screening Method:Ni Chem 1
Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W
% 1.18 18.43 <0.04 18.90 0.18 47.89 0.00 >5.48 3.13 0.31
STD 0.15 0.28 0.12 0.31 0.11 0.32 0.074 0.06 0.069 0.093
Grades: Inconel 718
Scaling Ref. : Inconel 718
Scaling Method: Ni ID

Method: 1 Metal Mode Sample: A46731 8/1/13 6:57:28 PM
Additional info: C4027
Duration: 5
Good Match
Reference: Inco 718
Difference: 33.03
Screening Method:Ni Chem 1
Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W
% 1.13 19.02 0.00 18.44 0.29 48.44 0.00 >5.34 2.89 0.42
STD 0.15 0.28 0.11 0.3 0.11 0.32 0.07 0.059 0.066 0.096
Grades: Inconel 718
Scaling Ref. : Inconel 718
Scaling Method: Ni ID

Method: 1 Metal Mode Sample: A46731 8/1/13 6:57:41 PM
Additional info: C4027
Duration: 5
Good Match
Reference: Inco 718
Difference: 27.10
Screening Method:Ni Chem 1
Analyte Ti Cr Mn Fe Co Ni Cu Nb Mo W
% 1.08 18.26 0.08 18.54 0.32 48.71 0.00 >5.37 2.88 0.34
STD 0.14 0.26 0.11 0.28 0.1 0.3 0.072 0.056 0.061 0.086
Grades: Inconel 718
Scaling Ref. : Inconel 718
Scaling Method: Ni ID

-----------------------------------------------------
thanks for your help

推荐答案

是否设置了格式?

这些是全部在一个文件中还是这些示例在单独的文件中?


我们不应该为你编写代码;但是,有些想法可以帮助你入门:


我会看标准的IO命令

有些人会使用文件脚本对象

ReadLN()

SPLIT()

在方法,附加等元素(0)中测试结果,并根据返回的选择案例进行操作处理表格的正确元素

如果不是eof然后循环/
Is the format set?
Are these all in one file or are these examples in seperate files?

We are not supposed to write the code for you; however, some ideas to get you started:

I''d be looking at the standard IO commands
Some would use the File Scripting Object
ReadLN()
SPLIT()
Test result in element(0) for Method, Additional, etc and select case for action based on that return to process the correct element for the table
if not eof then loop/


提取此数据可以像一系列If ... ElseIf一样简单.. .End如果语句如下所示:
Extracting this Data could be as simple as a series of If...ElseIf...End If Statements as indicated below:
展开 | 选择 | Wrap | 行号


谢谢ADezii,我想将这些提取的数据导入ms访问表,字段名称如下:

----- ------------------------------------

样品

日期

AdditionalInfo

参考

Ti

Cr

Mn

Fe

Co

Ni

Cu

Nb

Mo

W

ScalingRef

--------------------- ----------------------

无论如何都要这样做?
thank you ADezii, I will like to import these extracted data in to a ms access table with field names as below:
-----------------------------------------
Sample
Date
AdditionalInfo
Reference
Ti
Cr
Mn
Fe
Co
Ni
Cu
Nb
Mo
W
ScalingRef
-------------------------------------------
Is anyway to do it?


这篇关于如何将复杂的文本文件导入到ms访问中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆