Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > Indigo

Vista - Multiple endpoints

 
 
Old 03-04-2006   #1 (permalink)
q


 
 

Multiple endpoints

Aynone ever get this to work? This is a critical scenario... the
other critical scenario is having more than one endpoint on the same
IIS hosted service.

[Go-live version]

using System;
using System.ServiceModel;

namespace DemoStuff
{
[ServiceContract]
interface IDemoService
{
[OperationContract]
string GetText( );
}

class DemoService : IDemoService
{
public string GetText( ) {
{
return "Stuff";
}
}
}

class Program
{
static void Main(string[] args) {
Uri basicHttpUri = new
Uri("http://localhost:8081/Service/");
Uri httpDualUri = new
Uri("http://localhost:8082/Service/");
ServiceHost hService = new
ServiceHost(typeof(DemoService));

hService.AddServiceEndpoint(typeof(IDemoService), new
BasicHttpBinding( ), basicHttpUri);
hService.AddServiceEndpoint(typeof(IDemoService), new
WSDualHttpBinding( ), httpDualUri);

hService.Open( );
Console.WriteLine("Service at your service.");
Console.ReadKey( );
hService.Close( );

}
}
}


My System SpecsSystem Spec
Old 03-04-2006   #2 (permalink)
q


 
 

Re: Multiple endpoints

My System SpecsSystem Spec
 

Thread Tools


Similar Threads
Thread Forum
Multiple inboxes for multiple accounts Vista mail
Multiple cores, Multiple temps Overclocking & Cooling
Newbie question: replace multiple strings in multiple text files VB Script
Media Center Multiple Tuner Cards Multiple satellite services Vista music pictures video


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46