471,306 Members | 1,289 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,306 software developers and data experts.

An input of Decimal in a .Net Written COM exposed as wchar_t

Hi all, I have a COM that has a single function:

public Test(Decimal input)
{
return input;
}

From MSDN, it said that Decimal, be default, will be marshalled as COM's
Decimal
But I found that it become wchar_t

the MarshalAs Attribute only has Currency for decimal (but no "Decimal")

any idead what is happening?!

Thanks
Dec 6 '05 #1
1 1341
>From MSDN, it said that Decimal, be default, will be marshalled as COM's
Decimal
But I found that it become wchar_t


I assume you're using OleView to view the typelib. It has a bug in
that it incorrectly decompiles DECIMAL to wchar_t. So your interface
is probably correct after all.
Mattias

--
Mattias Sjögren [C# MVP] mattias @ mvps.org
http://www.msjogren.net/dotnet/ | http://www.dotnetinterop.com
Please reply only to the newsgroup.
Dec 6 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by whojustdenyme | last post: by
8 posts views Thread by Rui Maciel | last post: by
1 post views Thread by askalottaqs | last post: by
5 posts views Thread by j.smith2c | last post: by
14 posts views Thread by Ioannis Vranos | last post: by
reply views Thread by rosydwin | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.