Hello Pete,
I'm afraid that isn't possible, there is no attribute to avoid generating
description for the private component. Although you component is private
it visible through wsdl, but u can't create instance if you click on this
in IE
To hide it, you need manually remove 2 lines in web.config in the virtualRoot
of you component C:\WINDOWS\system32\com\SOAPVRoots\<name> and remove <wellknown>
and <activated> attribute for that class that marked Private
PW> Hello Michael,
PW>
PW> Thank you for your response. Allow me to try and further explain my
PW> question. Say I have three classes A, B and C. All three are
PW> serviced components. Class A looks something like this:
PW>
PW> namespace Demo
PW> {
PW> public class A : ServicedComponent
PW> {
PW> public A(){}
PW> public B GetB()
PW> {
PW> return new B();
PW> }
PW> public C GetC()
PW> {
PW> return new C();
PW> }
PW> }
PW> }
PW> In my AssemblyInfo.cs file I have the following line (among others
PW> of course):
PW>
PW> [assembly: ApplicationActivation(ActivationOption.Library,
PW> SoapVRoot="Demo")]
PW>
PW> Once I build the project, I then placed the assembly which contains
PW> all three classes into the global assembly cache and registered the
PW> dll using regsvcs.exe.
PW>
PW> At this point, I have a new COM+ Application called "Demo" which
PW> contains three components (A, B and C).
PW>
PW> Because of the SOAP attribute, I can open my browser to
PW> http://<computername>/Demo/default.aspx and see three links:
PW>
PW> Demo.A.soap?WSDL
PW> Demo.B.soap?WSDL
PW> Demo.C.soap?WSDL
PW> What I would like is to only see Demo.A.soap?WSDL. However, I have
PW> attemped to make B and C not visible using the ComVisible attribute
PW> without any success. I have also tried making B and C
PW> PrivateComponents but the links still appear. Any thoughts?
PW>
PW> Thank you again for your reply.
PW>
PW> Pete
PW>
PW> "Michael Nemtsev" wrote:
PW>
Take into account that [PrivateComponent] attribute is feature of
COM+ 1.5 that are included in Windows XP/2003 and above.
[PrivateComponent] mark component to be used only from within the
application, but not from the outside. In you case if you mark
components B and C as private only component A could use them.
Could you describe you problem wide?
Hello,
I am creating an app using Serviced Components and I am exposing
them using the Enterprise Services SOAP service. Here is my problem:
I have one COM+ application with several serviced components. When I
enable the SOAP service, I can access a WSDL link to every component
in the application. What I would like to do is the following: Have
a class A that is exposed through the SOAP service that provides
getters for instances of classes B & C. However I do not want B & C
to be directly accessed via the SOAP Service (i.e. I want a link
for A but not for B & C). Class A would be a sort of API for the
application.
So far, I've been playing with Private Component and ComVisibility
and have had no luck. Any thoughts?
-- WBR, Michael Nemtsev :: blog: http://spaces.msn.com/laflour
"At times one remains faithful to a cause only because its opponents
do not cease to be insipid." (c) Friedrich Nietzsche
---
WBR,
Michael Nemtsev :: blog:
http://spaces.msn.com/laflour
"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche