Click here to Skip to main content
15,908,172 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi all,
currently i am working on WCF project ,where i have to add more than one svc file in one wcf project. can anyone tell me is this possible to do
Thanks
Posted

Well yes you can, In that case every svc file need saprate "Contract". Also you should specify separate "End-Point" for each Conrtact.

Something as below.
XML
<system.serviceModel>

 <services>

  <service name="MyNamespace.Service1" behaviorConfiguration="MyBehaviorConfiguration">             

  <endpoint address="" binding="basicHttpBinding" contract="Mynamespace.IService1" />     
 
 </service>

  <service name="YourNamespace.Service2" behaviorConfiguration="MyBehaviorConfiguration">           

  <endpoint address="" binding="basicHttpBinding" contract="Mynamespace.IService2" />     
 
 </service>

 </services>

</system.serviceModel>
 
Share this answer
 
Yes you can have many many services. Each service just requires a unique name.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900