|
thanx
that's what I needed
|
|
|
|
|
I am working in a COM project where i need to communicate with Mainframes (CICS) for storing and retrieving data. So i want information about this problem like how to communicate or is there any interface useful for this situation?
|
|
|
|
|
I require a software component to be added to an existing .net application(web based). The coponent or the software should posses the following features:
1. It should provide PC to Phone integration either on VOIP technology or TAPI or both.
2. It should provide automated phone dialing from phone number lists.
3. Transfer calls to other users internally.
4. Record conversations and provide automated call reports and statistics.
5. Every phone number in the system should be automatically clickable and the call details must be logged to that user.
6. The phone call must be recorded and stored as a sound file.
Can anyone help me to find any freewares or commercial products available in the market which can provide me the above features.
Thanks in Advance
----------------------------------
where there is a will there is a way
|
|
|
|
|
Hi
I am writing two interfaces in two separate DLLs. The interfaces are named IID_Draw and IID_Draw, but I associate a unqiue GUID with each of the interfaces. Now when I create an interface pointer of the IID_Draw of the 1st DLL, how COM resolves this kind of calls.
|
|
|
|
|
- IID_DRAW is a constant you define in your code. The value of this constant is a unique GUID
- Now looking at your question, I believe you have got these constants defined either by wizard or #import or something similar.
If this is the case, then you have to resolve this ambiguity by explicitly specifiying the namespace (it has nothing to do with COM runtime, it's more about how you code the wrapper classes or constants).
For example if you have done #import <dll or="" tlb=""> in your code, then check the generated .TLH file. You will find namespace here.
I hope this helps.
S o h a i l K a d i w a l a
To Err Is Human; to Debug, Divine
modified 21-Apr-21 21:01pm.
|
|
|
|
|
I have a dll that implements connection points. Now I have a client that uses the dll using CreateInstance(..)& queryinterface. Now how do I receive events from the DLL. I guess it should be like registering a callback function for the events inside the dll? Dont know.. how to go?
----------------------------
286? WOWW!
|
|
|
|
|
- If you are not using MFC, Check IConnectionPointContainer and IConnectionPoint interfaces
- MFC has functions -> AfxConnectionAdvise and AfxConnectionUnadvise
S o h a i l K a d i w a l a
To Err Is Human; to Debug, Divine
modified 21-Apr-21 21:01pm.
|
|
|
|
|
Hello
Just read this article: COM Connection Points By Alex C. Punnen.
http://www.codeproject.com/com/connectionpoint.asp
Regards,
|
|
|
|
|
Hi there. Writing a WORD Addin for the first time. What I want to do is cycle through the characters in a WORD Doc. Everytime I find a particular character, I want to check what character comes after it. Depending on what I find I may want to add a new character.
My question is this:
Is there a way for me to access the actual stream of characters that make up the word doc? If not, am I right to assume the recommended approach to this is to make use of the find/replace mechanism offered by the object model?
Thanks,
Ciaran
Thanks,
Ciaran
|
|
|
|
|
Can anyone please help me or give me some sample code? I need to create an ATL COM service (not a DLL) which has a dummy interface.. say. add 2 numbers.. After creating the service, i want to register it as a windows service. Then i want to create a client which connects to this service and uses the interface.. (adds 2 numbers)
I have searched online and there is not a decent article which explains the process step by step... Any help in this regard will be very useful.
Thanks in advance!!!!
|
|
|
|
|
Hello,
Just read this book: Special Edition Using Visual C++.NET
by Kate Gregory
Regards,
|
|
|
|
|
I am creating "MFC AppWizard(Dll) with Automation" in VC++ 6.0, We are in the process of developing COM wrapper equivalent to java library for windows developers.
I am not able to find following equivalents of java in COM
- Defining Constant fields(as only interface is exposed, can we declare const fields in interface??)
- Defining and calling parameterizing constructor
Can anybody shade some light on this?
Thanks,
Bhavesh
|
|
|
|
|
COM objects cannot have parameterised constructors
COM interfaces can only contain method definitions, but you could declare a constant in a COM type library
- "I'm not lying, I'm just writing fiction with my mouth"Phil Harding. myBlog [^] | mySite [^]
|
|
|
|
|
Bhavesh Vaghela wrote: - Defining Constant fields(as only interface is exposed, can we declare const fields in interface??)
Since COM objects exposes interfaces only, you can only create a method returning a constant value. BTW you can define constats as enum , see the IDL reference.
Bhavesh Vaghela wrote: Defining and calling parameterizing constructor
You cannot do this, since you don't explicitely create a COM object, there's an associated ClassObject that do it for you.
Hope that helps.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
Bhavesh Vaghela wrote: I am not able to find following equivalents of java in COM
Java is a programming language, but COM is a technique that can be implemented in several languages e.g. C/C++, VB, Java etc. It doesn't make sense to compare those two.
Bhavesh Vaghela wrote: Defining Constant fields
I don't get what you mean by that, but perhaps a look at some IDL documentation[^] would help.
Bhavesh Vaghela wrote: Defining and calling parameterizing constructor
In COM you don't have a "constructor", you have a class factory that creates the instance which is created and called when the client calls ::CoCreateInstance(...) .
Technically you can have different constructors and edit the class factory to make use of them, but there's really no point. You should use persistent storage and monikers instead to let the server know how it should initialize itself.
"It's supposed to be hard, otherwise anybody could do it!" - selfquote "High speed never compensates for wrong direction!" - unknown
|
|
|
|
|
Hi,
I'm develpoing appication in C# and because of posible decompilation danger, we decided to use COM (created in VS 6 C++) for hiding code about licenses, isntead of obfuscating(which I think is not really helpfull). Is COM a good way how to hide/protect code, are there any ways to crack it (of course there are, but is it easy) ? Is there maybe some COM dll encrypting ?
thanx
|
|
|
|
|
How can wedisplay animated gifs and also able to type text in same window.
What type of window control lets you type text as well as put animated gif in it.
|
|
|
|
|
I have never gotten any answer from this site!!!!!
|
|
|
|
|
I have created an MFC ActiveX Control through the wizard. In the 2nd Step of the wizard I have enabled the checkbox saying “Available in Insert Object Dialog”, so that I can use my control in Microsoft Office Application like MS Word, Excel, PowerPoint etc using Insert Objects.
I am using property sheet to change the text contents of my control. For that I followed the steps mentioned the MSDN Example CIRC.
http://msdn2.microsoft.com/en-us/library/c6hzbzz6(VS.80).aspx
My control features the following characteristics.
• Changing the painting behavior of an ActiveX control
• Adding stock properties
• Adding custom properties
• Responding to mouse events
• Adding custom events
• Using text and fonts
• Implementing ActiveX control property pages
• Using simple data binding for control properties
But at present I am stuck up problems.
1. Using property sheet I can update the text contents in ActiveX test container. But it doesn’t get updated in Word, and other Office Applications. In fact its not even recognizing any of the event fired by the user (like changing the color on mouse click, key press etc) in any of the office application.
2. I am using this control for assigning digital signatures to a document. For that I am using X509 libraries. But these libraries use Common Language Runtime (/CLR) Support. And if I enable CLR from the project settings, the control crashes while loading on the Office application, ultimately crashing the entire document.
|
|
|
|
|
Dear friends,
What is the difference between BSTR and char*. I am writing a COM dll. It has an API which accepts a string (like patient name). Which datatype should be used? BSTR or char*? Please advice me.
Thanks in advance
Shihab
|
|
|
|
|
Loosely speaking, BSTR is a strange beast, it is zero-terminated like a standard C-string, but it is prefixed by its length like a Pascal one (dont' worry about that, there are API like SysAllocString , or even classes, like _bstr_t , that do the job for you).
That stated, BSTR is used for automation, so, if you have to interact with automation clients (for instance, scripting languages) then you have to use BSTR (BTW your server also needs to implement a dual interface ...). On the other hand, if your client is a standard Window application, written in C/C++, you can go also with char * (also Visual Basic code will be able to access you component, in a way similar to the one used to access Win32 API functionalities).
Hope that helps.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.
|
|
|
|
|
|
hi,
I've a COM object created in C++ , used in C# . I need to pass a string to that COM method, but always when I send string from C# , only first character occurs on C++ side.
COM Method:
STDMETHODIMP Initialize(LPTSTR a, LPTSTR b);
{
cout << "a: " << a << " b:" << b << endl;
....
}
if I call this method on that COM object (wrapped in C#)
IMyObject.Initialize("one", "two");
only thing i get in console is
a b:t
(instead of "a:one b:two")
how can i get whole size of string ??
|
|
|
|
|
here you pass as array may be it solve ur problem
Sujit
|
|
|
|
|
Try to send StringBuilder instances from C# application..
Cheers,
Suresh
|
|
|
|