|
Can I pass the registry key directly into CreateInstance instead of using a CLSID? How would I do that? I have the registry key as a string but I can't find a way to convert that string to a CLSID or pass it to CreateInstance.
Thanks!
KR
|
|
|
|
|
Could you show me your code?
|
|
|
|
|
Well it's just a CreateInstance call with a CLSID. It's like this:
m_Server.CreateInstance(SERVERLib::CLSID_Server);
And the CLSID passed into the function is correct in both debug and release versions. The dll is registered, I just don't understand why it won't load in release mode.
KR
|
|
|
|
|
I think you need to have the MFC Dlls for VS2005 in the system where you are testing the app.
However if you are testing it in the same system where VS 2005 is installed there is some other problem
"Every morning I go through Forbes list of 40 richest people in the world. If my name is not in there, I go to work..!!!"
|
|
|
|
|
Hi All,
I implemented a C# class library and registered it to be visible for COM objects, then i used it from VB6 application and it works fine. Now the problem is that i want to raise an event in the .NET COM and pass it as an event in VB6. i.e. when the .NET COM catched an exception i want it to raise event in the VB6 application to log the event (because the logger works there). Any ideas?
Thanks,
Mayy
|
|
|
|
|
MSDN[^]
Sohail
modified 21-Apr-21 21:01pm.
|
|
|
|
|
I'm stuck on the same thing right now. I think one option is to look up design patterns read up on the "Sender Observer Model" it will allow you to trigger a subroutine on the VB form and pass it arguements as well.
This will give you the same effect but it's not really answering the question I know. It is an alternative though.
Many Thanks,
Kiran
|
|
|
|
|
I have application developed in VC/COM/DCOM
At some point of time i got the following error message and application closed.
Faulting application <application name="">, version <version number="">, faulting module <module name="">, version <number>, fault address <hex address="">
Under what scenario does the above error occurs?
|
|
|
|
|
nilam2477 wrote: Under what scenario does the above error occurs?
Yours.
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.
[my articles]
|
|
|
|
|
Hi All
I want to integrate an “.exe” program in my application (C# Application) but I don’t know how to do that!
The .exe program is a decryption program that needs a password to decrypt files.
Also if it’s possible that I send directly the output (decrypted file) into my application not into a file.
Regard.
|
|
|
|
|
Does this 3rd part app provide COM interop? If so, read it's documentation and do what it says.IF not, I'd suggest you look at the Process class. If you need anything beyond command line interfacing though you're SOL using it.
Otherwise [Microsoft is] toast in the long term no matter how much money they've got. They would be already if the Linux community didn't have it's head so firmly up it's own command line buffer that it looks like taking 15 years to find the desktop.
-- Matthew Faithfull
|
|
|
|
|
Hi to all,
I created wrapper for the activex control created in vb
by aximp
i run aximp socx.ocx
socx is the name of my active x control.
Then i got two dll AXSOCXLIb and SOCXLib
i added to my .net 2003 reference folder then
i create object
Public X1 As New SOCXLib.SOCXClass
and pass all parameter to one of the method that is
str = gOutgoingNo & Trim(txtDialNo.Text)
g_NewCallRefID = 0
ip_addr = "130.1.12.21"
extn = 3308
X1.SCTMakeCall(str, "", g_NewCallRefID)
i got all the parameter but on last statment
when he call SCTMakeCall method i got
System.Runtime.InteropServices.COMException: Catastrophic failure
This is very urgent
please help me
|
|
|
|
|
Don't cross post. That is frowned upon, as well.
"I guess it's what separates the professionals from the drag and drop, girly wirly, namby pamby, wishy washy, can't code for crap types." - Pete O'Hanlon
|
|
|
|
|
Hey everybody!!
I need to know if the Document property of the WebBowser control (used by Internet Explorer) returns also the DOM elements created dynamically via Javascript or just the static ones defined on the page.
If anybody knows something about this, or has used the control and can give a hint on this, I will really appreciate it. Any ideas are welcome.
Thanks in advance,
Best regards,
Kenia
|
|
|
|
|
sorry... but why not simply test it yourself?
|
|
|
|
|
Hi,
I am new to MAPI and exchange. I need to develop a plugin/server that can process all messages (of all users) on the server. I've seen examples where extensions are written and hosted in COM+ apps. However, I could not find any concrete examples written in C++.
I would appreciate it very much if someone can point me to any articles/examples that show how to hook onto exchange and perform operations at a global level.
Even if not on global level, atleast how to register for callbacks and get events on messages being read/moved/deleted/reply etc would be great.
Thanks in advance,
Cheers
Raja
|
|
|
|
|
Hi,
I've written a COM+ server in C# (VS 2005) which I can successfully use in both delphi and c# windows applications. However, I also have a c# windows application which has a plugin architecture whereby it creates a separate application domain in which the plugins are loaded and unloaded. The problem is, if one of the plugins uses the COM Server, although everything works fine, including the unloading and loading of the plugins, when I close the application I get and "Attempted to read or write protected memory" error during the OleUninitialize stage. The COM Server has been loaded and registered using regsvcs and regasm, and installed in to the GAC. The problem exists when using both early and late binding. Viewing the names of all the assemblies held in the separate application domain created by the program I can see the COM Server listed.
Hope this is enough information.
Any help would be appreciated.
Many thanks.
|
|
|
|
|
I have a COM project that builds fine in VS 2005 pro that I'm trying to migrate to 2008 pro. When the project links though, I get an MIDL2025 error when it tries to link an interface method that uses an exported structure. Is there something that changed between the two versions, or is there something else that I have to set in the build environment? Here's a snippet that shows what I'm dealing with:
[export,library_block]
struct MSG
{
DWORD dwMsg;
DWORD dwID;
};
// _IEvents
[
object,
uuid("B0EE4D4C-7153-4844-9907-CAAEB5F4B214"),
helpstring("_IEvents Interface"),
pointer_default(unique)
]
__interface _IEvents: IUnknown
{
[id(1), helpstring("method MessageEvent")] HRESULT MessageEvent([in] MSG m);
};
|
|
|
|
|
Hello, I am a beginner within the COM programming. After I have seen some simple examples of COM, I have a question about it.
Could any one tell me when using COM within a VC project, after compile and link, is there any difference with other common VC projects?
Many thanks
|
|
|
|
|
Currently my the process I'm going through for each change of the C# code in the COM object is the following. Is there anyway I can streamline the number of manual steps involved?
Close the Excel spreadsheet using the COM object.
Build the COM object using VS03.
Open the spread sheet.
Open VBA.
Open the references dialog.
Remove the Missing:myObject reference.
Close the references dialog.
Reopen the references dialog.
Add the MyObject reference.
Close the references dialog.
Run the VBA.
Otherwise [Microsoft is] toast in the long term no matter how much money they've got. They would be already if the Linux community didn't have it's head so firmly up it's own command line buffer that it looks like taking 15 years to find the desktop.
-- Matthew Faithfull
|
|
|
|
|
Aside from writing log files or spitting out mesageboxes can I debug a managed COM (C#) object being called from within a VBA (excel) application?
Otherwise [Microsoft is] toast in the long term no matter how much money they've got. They would be already if the Linux community didn't have it's head so firmly up it's own command line buffer that it looks like taking 15 years to find the desktop.
-- Matthew Faithfull
|
|
|
|
|
I've found I can open my test spreadsheet automatically when i start my VS project using the debug properties page of the project. I've found a new showstopper though. The moment I try and run the calling VBA macro in my spreadsheet it closes excel and ends my VS debugging session. The same thing happens if I have it launch excel without a document and then manual open it using that copy of excel.
If I open the spreadsheet in a separate excel window the macro runs and calls the COM object successfully but my breakpoints in the C# code are ignored.
Otherwise [Microsoft is] toast in the long term no matter how much money they've got. They would be already if the Linux community didn't have it's head so firmly up it's own command line buffer that it looks like taking 15 years to find the desktop.
-- Matthew Faithfull
|
|
|
|
|
Does VS03 need to write the registry every time a COM object is recompiled, or only the first time?
Otherwise [Microsoft is] toast in the long term no matter how much money they've got. They would be already if the Linux community didn't have it's head so firmly up it's own command line buffer that it looks like taking 15 years to find the desktop.
-- Matthew Faithfull
|
|
|
|
|
Check Post-Build event in your Project properties
Sohail
modified 21-Apr-21 21:01pm.
|
|
|
|
|
THe post build event is empty. The registry fiddling is apparently being done elsewhere.
Otherwise [Microsoft is] toast in the long term no matter how much money they've got. They would be already if the Linux community didn't have it's head so firmly up it's own command line buffer that it looks like taking 15 years to find the desktop.
-- Matthew Faithfull
|
|
|
|