|
I have written a BHO application. This application works on Windows XP Home, Windows 2000 Pro and Windows XP Pro without SP 2 installed. After SP 2 was installed on Windows XP Pro the GetIDsOfNames function started failing with E_ACCESSDENIED (0x80070005). The GetIDsOfNames work succesfully one time and fails after that.
What does E_ACCESSDENIED mean when returned by GetIDsOfNames?
Why did SP 2 on Windows XP Pro cause this to start happening?
|
|
|
|
|
Hello,
I've heard of troubles with XP SP2 and COM... probably they want us to migrate our projects into .NET framework... I saw that also a COM taht uses sinks to synchronize processes does not work correctly with XP SP2, while it does good with oter OSs of NT family.
If I was you, I should check on MSDN if XP SP2 modifies behavior of GetIDsOfNames (usually they say it on function description...)
Hope this helps
Best regards
Morenz.
|
|
|
|
|
|
I had read some material about SP2. SP2 has some changes for BHO (Unfortunately, I dont have the paper now ). Please check for SP2 and BHO working on msdn.
Following link might be useful for understanding BHO in XP SP2 -
http://windowsxp.mvps.org/addons.htm[^]
Have a great day ahead!
Regards,
Sohail Kadiwala
(My Blog - http://blogs.wdevs.com/sohail/[^])
modified 21-Apr-21 21:01pm.
|
|
|
|
|
Hello Sohail,
Thank you very much for the response. I looked at the link in you message and also the links on that page.
I think there is something that I did not make clear. My BHO runs on Windows XP Pro SP 2. There is just one facility of the BHO that does not work. I have added items to the IE tools menu and buttons to the IE toolbar. These menu items and toolbar buttons do no work on Windows XP Pro SP 2. Everything else in my BHO is working. The BHO can be used without the menu items and buttons, but it is much more convenient to have them.
These items fail because they require the GetIDsOfName function. So, the links you provided did clear up some things for me, the did not help me find a resolution to my problem.
Someone must know what causes E_ACCESSDENIED to be returned from GetIDsOfNames.
Lonnie
|
|
|
|
|
Greetings,
Would you please help me with the following question?
Scenarios:
============================================================================
1. I have an XP Pro machine (A), and a Windows 2000 Standard Server (B).
2. I login both machine using the my domain account, which is administrator
of both machines.
3. I execute WBEMTest.exe running on an A to run a query against B.
. Namespace: \\B\root\cimv2
. Query: SELECT * FROM Win32_OperatingSystem
. Method: Asynchronous
4. The query runs without giving any error message, however, no result is
returned. (Operation in progress...)
5. I run the same test using Synchronous / Semisynchronous mode, they both
work fine and return me something.
============================================================================
How do I get it right? Tanks a million.
Best,
Jeff
|
|
|
|
|
Is there any good information out there on using this library. I'm trying to communicate with a printer via the COM 1 port but I can’t even open the port, so I’m kind of stuck.
|
|
|
|
|
Hi all,
First I know the handle of a window with a embeded webbrowser , in other process, how can i get IWebbrowser2 of the webbrowser? thx!
WalkSnail
-- modified at 4:34 Tuesday 1st November, 2005
|
|
|
|
|
|
Hello!
I'm developing an application, that should navigate web pages and store some wanted data... So i have decided to do it using an instance of IE.
Could you show me a simple exemple?
I need several functions:
- Create instance of IE
- Navigate browser to url
- Get source of loaded html
- Get text of loaded html (text that we see, looking at browser window)
I know, that this problem is not so difficult, by i can't slove it yet...
|
|
|
|
|
|
Thanks a lot
I use C#. May be there is some features in C# to simplify the problem? The fact is that i never used com in C#...
|
|
|
|
|
I don't know C# to greater extent. But anyways, incase there is no ready to use feature in C# for your problem, then you can obviously use the interface I mentioned. For COM in Managed code, read some articles on "COM Interoperability"
Have a great day ahead!
Regards,
Sohail Kadiwala
(My Blog - http://blogs.wdevs.com/sohail/[^])
modified 21-Apr-21 21:01pm.
|
|
|
|
|
This is really getting up my nose now.
How do you, using ATL7 in VS7.1, expose an external COM interface to your COM implementation?
If I import the type library (xxx.tlb), it complains of type definition.
This is a snippet of what's in my header file. The error code generated is listed below
Test.tlb is an external type library.
<br />
#import "Test.tlb" no_namespace<br />
<br />
[<br />
object,<br />
uuid("121574AA-841A-4FE0-871C-19A3C8C3C82F"),<br />
dual,<br />
pointer_default(unique)<br />
]<br />
__interface ITestPlugin : IDispatch<br />
{<br />
[id(1) HRESULT Process(LONG val, [out,retval] LONG* retval);<br />
[id(2) HRESULT RegisterSource(ITestSrv* source); <font color='red'>
};<br />
<br />
[<br />
coclass,<br />
threading("apartment"),<br />
vi_progid("Plug.TestPlugin"),<br />
progid("Plug.TestPlugin.1"),<br />
version(1.0),<br />
uuid("45D39585-BD2D-4F61-B0C7-A992F8CD8EF4"),<br />
helpstring("TestPlugin Class")<br />
]<br />
..<br />
..<br />
The error code is:
c:\temp\code\chincb\chinplug\testplugin.h(19) : error MIDL2025 : syntax error : expecting a type specification near "ITestSrv"
c:\temp\code\chincb\chinplug\testplugin.h(19) : error MIDL2026 : cannot recover from earlier syntax errors; aborting compilation
LINK : fatal error LNK1240: failed to compile IDL content
I'm scratching my hair out!
I Dream of Absolute Zero
|
|
|
|
|
Although I do not know what is in the imported test.tlb, the error message means that the interface ITestSrv has not been defined. I would check where ITestSrv exists and is defined, and make sure that your header file can see the definition.
|
|
|
|
|
Hi all! I'm new in COM therefore my question may seem strange.
(Beforehand I beg your pardon for my English
So, question is: Where I can found definition of some interface?
Let me explain (I use MS VC++ 6.0). Suppose I want to add in my program
Windows Media Player Control. Fist of all I create control:
....
CWnd m_PlayerWnd;
...
...
m_PlayerWnd.CreateControl(WMP_clsid,"", WS_VISIBLE|WS_CHILD, rect,&m_panel,AFX_IDW_PANE_FIRST);
then I get pointer to IUnknown:
LPUNKNOWN lpUnk = m_PlayerWnd.GetControlUnknown();
promlem is that I can't just do like this:
IWMPControl* pPlrControl;
and then get pointer to IWMPControl using lpUnk->QueryInterface and then
control Player through IWMPControl's methods cause MS VC++ 6.0 say that
'IWMPControl' undefined.
I can control Player through IDispatch's methods like GetIDsOfNames and Invoke, but
I think that control Player through IWMPControl is more comfortable.
So can you help me? Should I create this definition by hand or there is some anoter way?
Thanks In Advance.
Dmitry Dubinin
P.S. I know that there is wrapper class for WMPlayer in MS VC++ 6.0, but I choose WMPlayer
just for example.
|
|
|
|
|
If you use #import on the Media Player library, then you can create them by calling new with __uuidof. Then you can see the methods through intellisense.
Google __uuidof #import for heaps of examples.
Christian Graus - Microsoft MVP - C++
|
|
|
|
|
Hai All,
I Have to use a dll that is compiled in delphi 5.
Can it be used directly in the COM.
I am new to Com programming.
Actually if the dll generated in the Delphi is compatable i have to use it in my .net environment by writing a wrapper class.
Please help me.
SukanyaVarma
|
|
|
|
|
Hi,
I have developed an activeX control using the VB6,i have made a cab file of it,but the problem is that i need to script it using javascripting and in that , i am unable to call the function in the activeX which can provide me the data.
Let me be more precise, actually its an activeX to get the harware info of the system , every thing is fine but when it comes to collecting the reterived data , i am not finding any way to get it, i need a way in which it can be accessed.
I will be very thankful to the ones who can help me out.
please reply ASAP...
Zaheer.
|
|
|
|
|
Hi
Why do we register dlls? What is happening while registering a dll?
Which are the dlls to be registered?
Can anyone give me a link which expalins all these questions?
Thanks in advance
|
|
|
|
|
Diana Fernandez wrote: Why do we register dlls? What is happening while registering a dll?
"Registering" a dll usually means calling a certain function inside the dll by the name of 'DllRegisterServer'.
COM servers could be contained in dlls and the 'DllRegisterServer' function is responsible for creating the register keys and values that are related to the server in question. Those keys and values are ProgID, ClassID, TypeLibID, interface IDs, threading model, proxy/stub and so on.
Diana Fernandez wrote: Which are the dlls to be registered?
All dlls that needs to be registered.
Seriously, the install program takes care of this when you purchase a product.
If you are the developer you have to know whether your dll needs to be registered or not. Basically you can say "if 'DllRegisterServer' can be found in the dll it should be registered to be safe".
If you're asking for a list of dlls that are supposed to be registered I can tell you that there is no such thing. Dlls that require registring are developed each day by developers all over the world. There is no "book keeping" of all these dlls.
Hope this helps
--
Roger
It's supposed to be hard, otherwise anybody could do it!
|
|
|
|
|
Hi
Many Thanks
Diana
|
|
|
|
|
Hello,
I dont know, how to implementate a registration script
"hInstance needs to be the module / instance handle
of the module that contains your server registration
script (resource ID 102) .."
the server registration script is importand to
register my OPC Server.
RegisterServer()
HRESULT RegisterServer(void)
Return Values S_OK upon success, otherwise the result code
returned from the ATL registrar component.
The success of this operation is dependent on the application
including a registry script resource as part of its EXE.
The resource ID MUST be 102. An example resource script
is shown below:
HKCR
{
NDI.SimulationSvr.1 = s 'NDI Simulation Server'
{ CLSID = s '{1E52DE00-FA5E-11d2-91C6-F8E932000000}'
...
Best regards
Thomas
|
|
|
|
|
Never used ATL COM, but today I came across a little ATL COM test program, it is created by ATL COM AppWizard, all the settings are by default. a new ATL object was added into the project, and a new property Score with it.
STDMETHODIMP CContrl::put_Score(float newVal)
{
MessageBox("afsf");
return S_OK;
}
Then I inserted this ActiveX Contrl into another Dialog base project, and when Score property value was changed, the message box was prompted.
But the problem is when I add this contrl to a webpage inside Frontpage and going through the same process, the message box doesn't shows up
|
|
|
|
|
Hello,
I have a question related to interop between .NET and COM objects.
Many of the .NET apps I develop make use of a COM object that is accessed through the Mentor Graphics PADS software.
The PADS executables act as COM servers, allowing a VB or .NET program to "connect" to a PADS application object and its document object as a client.
The PADS applications are SDI apps, so there's always only one document object associated to the application object.
The problem I am having is that users want to be able to select one of multiple PADS servers, in case they have multiple PADS applications open. When I do a GetObject, I don't have any control over which COM object it gets.
Do you know how I can get the COM object associated to a specific server application, using Windows API or function calls, or can you point me in the direction to look for information?
Thanks,
Jerry Baldwin
Design Engineer
Everett Charles Technologies
Semiconductor Test Group
jerry.baldwin@ectinfo.com
|
|
|
|