确定在运行时从类型库中显示哪些功能 [英] Deciding which functions to show from Type Library at Runtime

查看:58
本文介绍了确定在运行时从类型库中显示哪些功能的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


Excel使用类型库显示自动化插件中的函数。这些函数显示在Excel的"插入函数"中。对话框(选择类别后)。


我想要做的是在运行时决定在Excel对话框中显示哪些功能。要求是在不同的SKU中显示不同的功能集。因此,如果安装了SKU-1,我想隐藏其他功能。


问题是Excel读取了一个类型库,我相信它是一个静态库。不确定我们是否可以在其中包含一些可以允许我们在运行时显示/隐藏方法的附加属性。类似于在
TLB中指定回调。



如果此帖子有用,请单击"投票为有用"箭头。

解决方案

嗨Abhimanyu,


感谢您发帖。


在做之前关于你的问题的一些研究,你能否提供有关以下问题的更多细节:


1。您对不同的SKU意味着什么?你能举个例子吗?


2。 Excel应用程序的版本是什么?


3。你是如何使用tlb的,你能告诉我们一些代码片段吗?


我将继续研究你的详细信息。


最好的问候,


Excel uses the type library to display functions from an automation addin. The functions are shown in Excel's "Insert Function" dialog (after choosing the category).

What I want to do is to decide at runtime which functions to display in Excel's dialog. The requirement is to display different set of functions in different SKUs. So if SKU-1 is installed, I want to hide the other functions.

The problem is that Excel reads a Type Library which I believe is a static library. No sure if we can have some additional attributes inside it that can allow us to show/hide methods at runtime. Something like specifying a callback from within the TLB.


Click the 'Vote as Helpful' arrow if this post was helpful.

解决方案

Hi Abhimanyu,

Thank you for posting.

Before doing some research about your problem, could you give more details about the following questions:

1. What do you mean about different SKUs? Could you give me the example?

2. What is the version of your Excel application?

3. How did you use the tlb and could you show us some code snippet?

I will do further research with your detailed information.

Best Regards,


这篇关于确定在运行时从类型库中显示哪些功能的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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