Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Problem with CreateObjectEx and Win Server 2003
Message
De
09/12/2005 17:57:38
 
 
À
09/12/2005 15:35:33
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Versions des environnements
Visual FoxPro:
VFP 9
OS:
Windows Server 2003
Network:
Windows NT
Database:
Visual FoxPro
Divers
Thread ID:
01076737
Message ID:
01076788
Vues:
24
I have seen the access denied error using VFP MTDLLs in COM+ on Server 2003. Here are steps to get things working in that environment. I haven't seen the event log event ID you describe, though.

I had to add roles to the component to avoid the "access is denied" error. Steps 8, and 14 - 16 describe the role configuration. Also, CREATEOBJECTEX() syntax is described in step 18 so no local registration is necessary on the clients.

These should form comprehensive instructions:

1. Take the MTDLL to the server machine and drop into the folder you wish to host it in. The runtimes need to be installed on the server as well.

2. On Windows Server 2003, click the Start button, and then Run. Type DCOMCNFG in the Run dialog box, and then click OK.

3. Expand Component Services, then Computers, then My Computer.

4. Right-click on COM+ Applications and select New, then Application, from the context menu.

5. In the COM+ Application Wizard, click Next.

6. Click the "Create an empty application" button. Enter a name, leaving the radio button on "Server application", then click Next twice, to go through the Set Application Identity page.

7. On the Add Application Roles tab, click Add Role. Enter AppUsers as the name of the role, then click OK. Click Next.

8. On the Add Users to Roles page, you will see the two Roles, CreatorOwner and AppUsers. Each of these will include the account you are logged in under when you create the application, as this is added by default. Expand AppUsers, and select Users. Click the Add button, and add any other local or domain users or local or domain groups you wish to allow access the application. When done, click Next.

9. Click Finish to close the wizard.

10. Expand COM+ Applications, and find the new application you just created.

11. Expand the newly added application. Right-click on Components, and select New, then Component from the context menu.

12. Click Next in the COM+ Component Install Wizard.

13. Click "Install New Component(s)" on the dialog, and navigate to your MTDLL. Click Next, then Finish.

14. To avoid an "Access is denied" error when calling remotely, you need to add your roles to the component. Rightclick on the newly added component. Select Properties. Click the Security tab.

15. Check the "Enforce component level access checks" checkbox.

16. Check the checkboxes next to AppUsers and CreatorOwner in the Name list. Click Apply.

17. Get the CLSID of the component. Click the General tab of the component Properties dialog in the Component. The CLSID is listed, and you can highlight the text with the mouse, and copy it.

Network COM+ must be enabled on the server. For info on how to do this in Windows Server 2003, see: 817065 How to enable network COM+ access in Windows Server 2003
http://support.microsoft.com/default.aspx?scid=kb;EN-US;817065


18. To call from a remote machine use code as below
MyObj = CreateObjectEX("{CLSID}","<servername>")
where CLSID is the CLSID, including the bracketting {} characters, from step 17 above.

Example:
xx = CreateObjectEx('{A2EAAE4F-4B00-4107-8E9F-214C38E4CE4D}','chinadoll')
Maybe these steps will be helpful to you!


>Using VFP9. The domain I'm working on is currently NT4 containing some member servers running Windows server 2003. Calls to CreateObjectEX work fine to launch remote com servers on the NT4 machines, but fail with the Win2k3 servers. On the Win2k3 machines I can launch the servers locally with no problem. I have used DComCnfg to set up the proper launch and activation permissions - making sure everything is identical to the NT4 boxes. When I try to create the server remotely, the call to CreateObjectEX fails with the error: "0x80070005: Access is denied". On the Win2K3 server in the event log I get the following error:
>"ID 36872: No suitable default server credential exists on this system. This will prevent server applications that expect to make use of the system default credentials from accepting SSL connections."
>Does this mean that I need to install a certificate on the server to enable the remote RPC connections?
>
>Thanks and regards - Bill
Jim Saunders
Microsoft
This posting is provided “AS IS”, with no warranties, and confers no rights.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform