导出到XML文件 [英] Exporting To XML File

查看:76
本文介绍了导出到XML文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

2000X模式下的AccessXP。


我正在使用Application.ExportXML运行一个程序。 XML文件以
开头:

<?xml version =" 1.0"编码= QUOT; UTF-8英寸?>

- < dataroot xmlns:od =" urn:schemas-microsoft-com:officedata">

- < QryExportWOOnSelectedShowDate>


我在每条记录的数据之间得到以下结果:

< QryExportWOOnSelectedShowDate>

- < QryExportWOOnSelectedShowDate>


有没有人知道是否有办法防止XML文件中的这些条目

因此所有文件都包含数据?


谢谢!


史蒂夫

AccessXP in 2000 mode.

I am running a procedure using Application.ExportXML. The XML file begins
with:
<?xml version="1.0" encoding="UTF-8" ?>
- <dataroot xmlns:od="urn:schemas-microsoft-com:officedata">
- <QryExportWOOnSelectedShowDate>

and I get the following between each record''s data:
<QryExportWOOnSelectedShowDate>
-<QryExportWOOnSelectedShowDate>

Does anyone know if there is a way to prevent these entries in the XML file
so all the file contains is data?

Thanks!

Steve

推荐答案

我怀疑你所看到的是格式良好的XML - 为什么你要b $ b想要消除它的任何部分以使其不那么好?是否
没有正确导入到目标应用程序中,并且您已经确定这些特殊的标记项目会阻止它这样做吗?

如果你想要的只是数据,你可以使用逗号分隔的文本(又名

逗号分隔变量,CSV)。


通常,使用XML的唯一原因是数据将转到接受XML的

应用程序。否则,你会想要以其他一些

格式导出。


Larry Linson

Microsoft Access MVP
" PC数据表" <无**** @ nospam.spam>在消息中写道

新闻:GM ***************** @ newsread1.news.atl.earthl ink.net ...
I suspect that what you are seeing is "well-formed XML" -- why would you
want to eliminate any part of it to make it "not-so-well-formed"? Does it
not import properly into the target application, and you have determined
that it is these particular markup items that prevent it doing so?

If all you want is data, you could use comma-delimited text (aka
comma-separated-variable, CSV) instead.

The only reason to use XML, generally, is that the data is going to an
application that accepts XML. Otherwise, you''d want to export in some other
format.

Larry Linson
Microsoft Access MVP
"PC Datasheet" <no****@nospam.spam> wrote in message
news:GM*****************@newsread1.news.atl.earthl ink.net...
AccessXP在2000模式。

我正在使用Application.ExportXML运行一个过程。 XML文件以
<?xml version =" 1.0"开头。
编码= QUOT; UTF-8英寸?>
- < dataroot xmlns:od =" urn:schemas-microsoft-com:officedata">
- < QryExportWOOnSelectedShowDate>

我得到了跟踪每个记录的数据:
< QryExportWOOnSelectedShowDate>
- < QryExportWOOnSelectedShowDate>

有谁知道是否有办法阻止XML中的这些条目
文件,所有文件包含的是数据吗?

谢谢!

AccessXP in 2000 mode.

I am running a procedure using Application.ExportXML. The XML file begins
with:
<?xml version="1.0" encoding="UTF-8" ?>
- <dataroot xmlns:od="urn:schemas-microsoft-com:officedata">
- <QryExportWOOnSelectedShowDate>

and I get the following between each record''s data:
<QryExportWOOnSelectedShowDate>
-<QryExportWOOnSelectedShowDate>

Does anyone know if there is a way to prevent these entries in the XML
file so all the file contains is data?

Thanks!

Steve




" PC数据表"写道:

"PC Datasheet" wrote:
2000X模式下的AccessXP。

我正在使用Application.ExportXML运行一个程序。 XML文件以
<?xml version =" 1.0"开头。
编码= QUOT; UTF-8英寸?>
- < dataroot xmlns:od =" urn:schemas-microsoft-com:officedata">
- < QryExportWOOnSelectedShowDate>

我得到了跟踪每个记录的数据:
< QryExportWOOnSelectedShowDate>
- < QryExportWOOnSelectedShowDate>

有谁知道是否有办法阻止XML中的这些条目
文件,所有文件包含的是数据吗?
AccessXP in 2000 mode.

I am running a procedure using Application.ExportXML. The XML file begins
with:
<?xml version="1.0" encoding="UTF-8" ?>
- <dataroot xmlns:od="urn:schemas-microsoft-com:officedata">
- <QryExportWOOnSelectedShowDate>

and I get the following between each record''s data:
<QryExportWOOnSelectedShowDate>
-<QryExportWOOnSelectedShowDate>

Does anyone know if there is a way to prevent these entries in the XML
file so all the file contains is data?



你好Steve,


我的工作的一小部分是拿大学

行计划数据并将报告打印到pdf

文件。我使用pdf995,如果它们在xml中,则允许在报告打印后添加书签

。文件

不是格式正确。


当我打印报告时,我保存了页码,

学院和部门的表格。


然后我运行一个函数将这些数据写入xml中。他们要求的格式为

打开一个文件输出,通过

a记录集循环到上面的表格,并打印

行到该文件。


所以......自己动手并不难。

如果你愿意,我可以发布代码,但

表格输出是特定的

pdf995书签。


我很好奇,但你会怎么期待

"报头QUOT; xml中的记录....


gary


Hi Steve,

One small part of my job is to take University
Line Schedule data and print a report to a pdf
file. I use pdf995 which allows adding Bookmarks
after report has printed if they are in a "xml" file
which is not "well-formed."

As I print the report, I save Page number,
College, and Dept in a table.

I then run a function that writes this data
to the "xml" file in form they require by
opening a file for output, cycling through
a recordset to table above, and printing
lines to the file.

So...it''s not difficult to "do-it-yourself."
If you''d like, I could post the code, but
the "form" of the output is specific to
pdf995 bookmarks.

I''m curious though as to how you would expect to
"header" a record in your xml....

gary


" PC数据表" <无**** @ nospam.spam>在消息中写道

新闻:GM ***************** @ newsread1.news.atl.earthl ink.net
"PC Datasheet" <no****@nospam.spam> wrote in message
news:GM*****************@newsread1.news.atl.earthl ink.net
AccessXP在2000模式下。

我正在使用Application.ExportXML运行一个过程。 XML文件
以:
<?xml version =" 1.0"编码= QUOT; UTF-8英寸?>
- < dataroot xmlns:od =" urn:schemas-microsoft-com:officedata">
- < QryExportWOOnSelectedShowDate>


实际上,标签之前的破折号是互联网神器资源管理器,反映了分层节点结构的扩展 -

他们不在XML文件本身,因为你会看到你在

记事本中编辑它。

我在每个文件之间得到以下内容记录的数据:
< QryExportWOOnSelectedShowDate>
- < QryExportWOOnSelectedShowDate>

有谁知道在
XML中是否有办法阻止这些条目文件,所有文件包含的是数据?
AccessXP in 2000 mode.

I am running a procedure using Application.ExportXML. The XML file
begins with:
<?xml version="1.0" encoding="UTF-8" ?>
- <dataroot xmlns:od="urn:schemas-microsoft-com:officedata">
- <QryExportWOOnSelectedShowDate>
Actually, the dashes that precede the tags are an artifact of Internet
Explorer, reflecting the expansion of a hierarchical node structure --
they aren''t in the XML file itself, as you''ll see if you edit it in
Notepad.
and I get the following between each record''s data:
<QryExportWOOnSelectedShowDate>
-<QryExportWOOnSelectedShowDate>

Does anyone know if there is a way to prevent these entries in the
XML file so all the file contains is data?




那些标签,我期待的确是< QryExportWOOnSelectedShowDate>

....数据

XML结构需要元素...< / QryExportWOOnSelectedShowDate>。每对标记由XML文件表示的文档元素的开头和结尾

。在这种情况下,

元素是一条记录。你不能摆脱它们,仍然有一个

格式良好的XML文档。


-

Dirk Goldgar,MS Access MVP
www.datagnostics.com


(请回复新闻组)



Those tags, which I expect are really <QryExportWOOnSelectedShowDate>
.... data elements ... </QryExportWOOnSelectedShowDate>, are required by
the XML structure. Each pair marks the beginning and end of an element
of the document being represented by the XML file. In this case, the
element is a record. You can''t get rid of them and still have a
well-formed XML document.

--
Dirk Goldgar, MS Access MVP
www.datagnostics.com

(please reply to the newsgroup)


这篇关于导出到XML文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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