avatar
l*n
1
I have a excel file containing many VB codes. I need to save the results as
records. But I do not want the buttons and VB codes saved in the records.
How can I do that? Now I am using saveas, and set the buttons in records
invisible. The codes are still there.
Thanks you,
avatar
b*e
2
If you can provide some screen shot, it will be better for people to learn
what you are doing.

as

【在 l******n 的大作中提到】
: I have a excel file containing many VB codes. I need to save the results as
: records. But I do not want the buttons and VB codes saved in the records.
: How can I do that? Now I am using saveas, and set the buttons in records
: invisible. The codes are still there.
: Thanks you,

avatar
S*k
3
I guess you have VB code to create the excel file, and the created excel
file includes not only the results but the VB code itself also.
If this is the case, you may try
This.Visible = false;
Response.clear();
Response.ClearContent();
Response.ClearHeaders();
Response.WriteFile(…);
Response.End();
avatar
c*t
4
FYI: http://www.vb-helper.com/howto_excel_save_without_macros.html

as

【在 l******n 的大作中提到】
: I have a excel file containing many VB codes. I need to save the results as
: records. But I do not want the buttons and VB codes saved in the records.
: How can I do that? Now I am using saveas, and set the buttons in records
: invisible. The codes are still there.
: Thanks you,

avatar
c*t
5
another approach is to use VSTO. End user will see data, all code behind are
binary code, invisible to them.

as

【在 l******n 的大作中提到】
: I have a excel file containing many VB codes. I need to save the results as
: records. But I do not want the buttons and VB codes saved in the records.
: How can I do that? Now I am using saveas, and set the buttons in records
: invisible. The codes are still there.
: Thanks you,

avatar
l*n
7
thanks

【在 S***k 的大作中提到】
: I guess you have VB code to create the excel file, and the created excel
: file includes not only the results but the VB code itself also.
: If this is the case, you may try
: This.Visible = false;
: Response.clear();
: Response.ClearContent();
: Response.ClearHeaders();
: Response.WriteFile(…);
: Response.End();

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。