Mohammed 的个人资料Dynamics AX日志留言簿网络 工具 帮助

日志


1月18日

Using the COM Class Wrapper in AX 2009

 

COM Class wrapper is a immensely useful and phenomenally easy to use tool..

Basically it wraps COM objects and make them available to you (a developer) just like a normal x++ class.

You dont necessarily have to use the com wrapper to be able to use com objects.. the old and handy class COM (http://msdn.microsoft.com/en-us/library/aa655160.aspx) is sufficient.. however (with all due respect to the COM class) intellisense does not work with the COM class hence as a developer you either need to know what the com methods are (and their signatures) or you continuously will be flicking though developer documentation on the com interface.

Well COM class wrapper basically put intellisense into COM...... you can say that the COM Wrapper is to COM what References is to .Net

I would like to point out that MS discourages the use of the COM interfaces in AX. Hence, if you have the option, then consider taking the .Net route.

You can find the COM Wrapper under Developer Tools > Wizards > COM Class Wrapper

clip_image002

clip_image004

It does exactly what is says on the tin..

In the next screen one would see a list of all registered com libraries..

clip_image005

Select the one that you are looking for and click next... (the office 12 object library is a bad example.. as I could have done the same thin using References, which is the recommended method).

clip_image007

Specify an element mask.. this makes it easier to find the objects in the AOT. It also resolves the possibility of name conflicts.

clip_image009

So in this example mrOff was the Element Mask.

 

- Mohammed Rasheed

www.dynamic-ax.co.uk

评论

请稍候...
很抱歉,您输入的评论太长。请缩短您的评论。
您没有输入任何内容,请重试。
很抱歉,我们当前无法添加您的评论。请稍后重试。
若要添加评论,需要您的家长授予您相应权限。请求权限
您的家长禁用了评论功能。
很抱歉,我们当前无法删除您的评论。请稍后重试。
您已超过了一天之内允许提供的评论数上限。请在 24 小时后重试。
因为我们的系统表明您可能在向其他用户提供垃圾评论,您的帐户已禁用了评论功能。如果您认为我们错误地禁用了您的帐户,请联系 Windows Live 支持部门
完成下面的安全检查,您提供评论的过程才能完成。
您在安全检查中键入的字符必须与图片或音频中的字符一致。

若要添加评论,请使用您的 Windows Live ID 登录(如果您使用过 Hotmail、Messenger 或 Xbox LIVE,您就拥有 Windows Live ID)。登录


还没有 Windows Live ID 吗?请注册

引用通告

此日志的引用通告 URL 是:
http://dynamic-ax.spaces.live.com/blog/cns!13619E6948204DE3!386.trak
引用此项的网络日志