Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 129333
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T05:46:27+00:00 2026-05-11T05:46:27+00:00

What is the correct pattern or method for developing a Silverlight application (which is

  • 0

What is the correct pattern or method for developing a Silverlight application (which is the Silverlight project and Web Application in a single solution)? I mean, how do you add the Service Reference if the localhost port number will be constantly changing?

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T05:46:27+00:00Added an answer on May 11, 2026 at 5:46 am

    If you select the web project in the Solution Explorer, you can change a property in the Properties tool window that will stop the port from changing. The property is called ‘Use dynamic ports’ and you want to set it to false so that the port remains static.

    You can also specify the port number in these settings.

    Note that this is not in the project’s property pages, but in the Properties tool window (which is probably why it’s so hard to find – took me quite some time to work this one out myself).

    Update

    To switch between deployment and development, I tend to specify two SOAP bindings and then use #ifdef DEBUG to switch the binding of my SOAP client based on the type of build. The DEBUG build points to the development services, and the RELEASE build points to the deployed services.

    So, my ClientConfig is something like:

    <configuration>   <system.serviceModel>     <bindings>       <basicHttpBinding>         <binding name='Soap_Debug' maxBufferSize='2147483647'           maxReceivedMessageSize='2147483647'>           <security mode='None' />         </binding>         <binding name='Soap_Release' maxBufferSize='2147483647'           maxReceivedMessageSize='2147483647'>           <security mode='None' />         </binding>       </basicHttpBinding>     </bindings>     <client>       <endpoint address='http://www.mymadeupurl.com/myservices.asmx'         binding='basicHttpBinding' bindingConfiguration='Soap_Release'         contract='MyServices.MyServicesSoap' name='Soap_Release' />       <endpoint address='http://localhost:1929/mydservices.asmx'         binding='basicHttpBinding' bindingConfiguration='Soap_Debug'         contract='MyServices.MyServicesSoap' name='Soap_Debug' />     </client>   </system.serviceModel> </configuration> 

    I create instances of the SOAP client like this:

    #if DEBUG    // localhost hosts the web services in debug builds.    soapClient = new MyServicesSoapClient('Soap_Debug'); #else    // The web services are hosted in a different location for release builds.    soapClient = new MyServicesSoapClient('Soap_Release'); #endif 
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am developing a web application with PHP and MySQL. I have an entity
jQuery uses this pattern. Essentially it involves every method returning a reference to the
Given a html document, what is the most correct and concise regular expression pattern
Which is the most correct code? if (HttpContext.Current.Response.Cookies[authCookieName] != null) { HttpContext.Current.Response.Cookies[authCookieName].Value = New
Edit: Answered - error was method wasn't static I'm used the Singleton Design Pattern
Correct me if I'm wrong, but a build is a compile, and not every
Correct me if I am wrong, int is 4 bytes, with a range of
Am I correct in assuming that the only difference between "windows files" and "unix
What is the correct way to import a C++ class from a DLL? We're
Someone please correct me if I'm wrong, but parsing a yyyy/MM/dd (or other specific

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.