TransferText使用.txt文件名变量导入 [英] TransferText Import with .txt file name variable
问题描述
我有一个访问数据库,它使用vba从特定位置检索.txt文件,并将它们放在访问数据库中的特定表中。以前(多年),.txt文件名一直是静态的(例如:ErrRpt.txt)。现在,使用此数据库的受众已更改.txt文件名以包含每日附加的日期(YYYMMDD)(例如:ErrRpt_20090520.txt)。
有人可以帮我吗更改以下代码行(我需要更改的许多行的示例)以导入具有不同日期的.txt文件?
这样的事情应该工作
<跨度类= codeLink 的onclick = 模糊(这,这个is.parentNode.parentNode,getChildren(this),true);>展开 | 选择 | Wrap | 行号
很好!让我抓住它。 BRB。谢谢
很棒的帮助Denburt !!!!如果我需要有时间(HHMM)的格式,那将是什么样子?
可能这样吗?
&格式(日期,yyyymmdd,时间" hhmm")
I have an access database that uses vba to retrieve .txt files from a specific location and places them in specific tables within the access database. Previously (many years), the .txt file names have always been static (e.g.: ErrRpt.txt). Now, the audience that uses this database has changed the .txt file names to include a date (YYYMMDD) that is appended daily (e.g.: ErrRpt_20090520.txt).
Can someone help me change the following line of code (an example of many lines that I need to change) to import the .txt file with varying dates?
Expand|Select|Wrap|Line Numbers解决方案Something like this should work
Expand|Select|Wrap|Line Numbers
nice! let me take it for a spin. brb. thank you
Great help Denburt!!!! If i needed to had time (HHMM) to the format how would that look?
like this maybe?
& Format (date, "yyyymmdd", time "hhmm")
这篇关于TransferText使用.txt文件名变量导入的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文登录 关闭
扫码关注1秒登录发送“验证码”获取 | 15天全站免登陆