打开html文档时传递变量的问题。首次运行后,保存的文档将覆盖它 [英] problems passing variable when opening html document. First time it works after that the saved document overrides it

查看:66
本文介绍了打开html文档时传递变量的问题。首次运行后,保存的文档将覆盖它的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我们的DLL创建/打开文档时,我们将变量app_name设置为Monarch或VoteTech。 当文档保存为html文档时,其中包含app_name的html文件中的xml部分。这是一个
的样本:

<! - [if gte mso 9]>< xml>

< w:WordDocument>

< w:app_name> Monarch< / w:app_name>

When our DLL creates/opens a document we are passing a variable app_name set to either Monarch or VoteTech.  When the document gets saved as an html document there is an xml section in the html file which contains app_name. Here is a sample of it:
<!--[if gte mso 9]><xml>
<w:WordDocument>
<w:app_name>Monarch</w:app_name>

问题是如果重新打开文件并在命令行上传递了不同的app_name该值未被使用。 相反,&NBSP;似乎使用了app_name的html文件设置中的内容。

The problem is if the file is reopened and a different app_name is passed on the command line the value doesn't get used.  Instead,  it appears that what ever the is in the html file setting for app_name is used.

有没有办法阻止在html文件中仅保存app_name? 还有其他想法吗?

Is there a way to prevent the saving of just the app_name in the html file?  Any other ideas?

推荐答案

Hi Wayne

Hi Wayne

VSTO技术在你的角色扮演什么角色应用程序?

What role does the VSTO technology play in your application?

我们正在处理哪个版本的Word?

Which version of Word are we dealing with?

您的DLL用于创建/打开(Word?)文档的代码是什么?并传递变量app_name?

What is the code your DLL uses to create/open a (Word?) document? And to pass the variable app_name?


这篇关于打开html文档时传递变量的问题。首次运行后,保存的文档将覆盖它的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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