|
Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com |
From: David (onebeloved_at_YAHOO.COM)
Date: Fri Sep 06 2002 - 17:06:06 CDT
I am using an object reference moniker to put an
object on to the ROT and then I pass the display name
to an object which attempts to retrieve the object.
The code snippet is as follows:
// put on ROT
hr = CreateBindCtx (0, &m_pBindCtx);
hr = CreateObjrefMoniker(pUnk, &m_pMoniker);
m_pMoniker->GetDisplayName(m_pBindCtx, NULL,
&pName);
hr = m_pBindCtx->GetRunningObjectTable
(&m_pRot);
hr =
m_pRot->RegisterROTFLAGS_REGISTRATIONKEEPSALIVE,
pUnk, m_pMoniker, &m_dwRotId);
// pass display name to client who dereferences
hr = ::CreateBindCtx (0, &pBindCtx);
hr = ::MkParseDisplayName (pBindCtx, pName, ulEaten,
&pMoniker);
hr = pMoniker->BindToObject(pBindCtx, NULL,
IID_IAuthorProject, (LPVOID*) &pProj);
In Windows XP & 2K, there are no problems. On
Windows 98/Me, the call to MkParseDisplayName is
returning 0x800401ea (Moniker cannot open file ).
Any ideas?
Thanks,
David
__________________________________________________
Do You Yahoo!?
Yahoo! Finance - Get real-time stock quotes
http://finance.yahoo.com
----------------------------------------------------------------
Users Guide http://discuss.microsoft.com/archives/mailfaq.asp
contains important info. Save time, search the archives at
http://discuss.microsoft.com/archives/index.html .
To unsubscribe, mailto:DCOM-signoff-request
DISCUSS.MICROSOFT.COM
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]