Click here to Skip to main content
15,908,112 members
Home / Discussions / COM
   

COM

 
QuestionHow to create new object in C# for reading COM port. Pin
gaurav_quexst9-Apr-09 1:57
gaurav_quexst9-Apr-09 1:57 
AnswerRe: How to create new object in C# for reading COM port. [modified] Pin
Vozzie29-Apr-09 6:23
Vozzie29-Apr-09 6:23 
QuestionAdd-in express.. Pin
gothic_coder9-Apr-09 1:11
gothic_coder9-Apr-09 1:11 
QuestionIs VariantChangeType() have problem with BSTR to VT_I4 conversion with even numbers and odd numbers Pin
Shankarcodebase8-Apr-09 5:48
Shankarcodebase8-Apr-09 5:48 
AnswerRe: Is VariantChangeType() have problem with BSTR to VT_I4 conversion with even numbers and odd numbers Pin
Ujjwal Gangwal11-Jun-19 6:05
professionalUjjwal Gangwal11-Jun-19 6:05 
QuestionDLL missing? Pin
tom5720078-Apr-09 2:49
tom5720078-Apr-09 2:49 
AnswerRe: DLL missing? Pin
tom5720078-Apr-09 2:57
tom5720078-Apr-09 2:57 
QuestionVB ActiveX in C# Pin
tvks8-Apr-09 2:13
tvks8-Apr-09 2:13 
Hi,

I have a VB code (ActiveX ExE) which has a VB form called DocX.

This form has a GET property (name it retProp) which returns an object.

I have compiled the ActiveX EXE and later used tlbimp from dotnet to generate an Interop.MyProject.dll

Later I have included this dll as a reference in my C# project.

Now I am getting the namespace MyProject.MyInterface.

When I use the following code it says "true"

if (MyInterface.Windows.Exist(ref data) == true)


--> MyInterface.Windows.Exist(ref data) returns the MyInterface.Windows.Window as object

Because MyInterface.Windows.getItem(ref data).Form is returned as an object to me I am not able to Unbox it. I get an error :
System.InvalidCastException: Unable to cast COM object of type 'System.__ComObject' to class type 'VB.Form'. COM components that enter the CLR and do not support IProvideClassInfo or that do not have any interop assembly registered will be wrapped in the __ComObject type. Instances of this type cannot be cast to any other class; however they can be cast to interfaces as long as the underlying COM component supports QueryInterface calls for the IID of the interface.

Pls help.

Regards,

tvks
Questionhow to fix the IWebBrowser2 refresh problem Pin
benpeng2-Apr-09 22:56
benpeng2-Apr-09 22:56 
QuestionFree threaded model Pin
_80862-Apr-09 21:25
_80862-Apr-09 21:25 
AnswerRe: Free threaded model Pin
Roger Stoltz2-Apr-09 21:50
Roger Stoltz2-Apr-09 21:50 
GeneralRe: Free threaded model Pin
_80862-Apr-09 22:43
_80862-Apr-09 22:43 
GeneralRe: Free threaded model Pin
_80862-Apr-09 22:53
_80862-Apr-09 22:53 
AnswerRe: Free threaded model Pin
Roger Stoltz2-Apr-09 23:04
Roger Stoltz2-Apr-09 23:04 
GeneralRe: Free threaded model Pin
_80862-Apr-09 23:16
_80862-Apr-09 23:16 
QuestionHow to set the URL property of a WMP object in a Word .doc file? Pin
wangdave2-Apr-09 14:49
wangdave2-Apr-09 14:49 
QuestionLooking for links, books, articles on building .NET assemblies for use as COM servers Pin
cpkilekofp2-Apr-09 10:07
cpkilekofp2-Apr-09 10:07 
AnswerRe: Looking for links, books, articles on building .NET assemblies for use as COM servers Pin
Baltoro4-Apr-09 8:50
Baltoro4-Apr-09 8:50 
QuestionControl connection to EXE when calling CreateDispatch Pin
Tim Cook2-Apr-09 5:50
Tim Cook2-Apr-09 5:50 
AnswerRe: Control connection to EXE when calling CreateDispatch [modified] Pin
Baltoro4-Apr-09 10:00
Baltoro4-Apr-09 10:00 
GeneralSorry Pin
Baltoro4-Apr-09 11:11
Baltoro4-Apr-09 11:11 
GeneralRe: Sorry Pin
Tim Cook6-Apr-09 8:00
Tim Cook6-Apr-09 8:00 
GeneralI'll Try to Explain Clearly Pin
Baltoro9-Apr-09 10:32
Baltoro9-Apr-09 10:32 
GeneralRe: I'll Try to Explain Clearly Pin
Tim Cook17-Apr-09 5:31
Tim Cook17-Apr-09 5:31 
Questionactivex loading from tomcat 6 Pin
aysl2-Apr-09 5:28
aysl2-Apr-09 5:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.