Setting "URL Behaviour" to "Dynamic" has no effect

Discussion in 'ASP .Net Web Services' started by Hans Malherbe, Jun 10, 2005.

  1. Greetings

    When I set the "URL Behaviour" of a web reference an entry is created
    in the "Web.config", but the value in the "Web Reference URL" property
    is still used.

    When I look in the file "Reference.cs" I can see that "this.Url" is set
    in the
    constructor of the reference class to the hard coded value in the "Web
    Reference URL". If I change this line in the generated code to read:

    this.Url = ConfigurationSettings.AppSettings["Whatever.x"];

    it takes the configured value and everything works. The only problem is
    that "Update Web Reference" restores this to the original value.

    Is there a sane way around this. I would like to have the dynamic
    reference take the URL from the "Web.Config" and not change when I
    update the web reference.

    Thanks in advance
    Hans
    Hans Malherbe, Jun 10, 2005
    #1
    1. Advertising

  2. Solved.

    It seems that if the name of the web reference contains the word
    "Static" the file "Reference.cs" will not get updated when you change
    the behaviour from static to dynamic.

    Groete
    Hans
    Hans Malherbe, Jun 13, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. John E. Jardine

    s/// has apparent side effect on grep()

    John E. Jardine, Apr 12, 2004, in forum: Perl
    Replies:
    2
    Views:
    441
    John Jardine
    Apr 13, 2004
  2. Doug
    Replies:
    3
    Views:
    3,054
    PeterBrunone
    Dec 7, 2006
  3. Nathan Sokalski
    Replies:
    8
    Views:
    3,569
    Nathan Sokalski
    Dec 5, 2005
  4. Maciej Kalisiak

    "ulimit -s" has no effect?

    Maciej Kalisiak, Feb 5, 2004, in forum: Python
    Replies:
    16
    Views:
    2,147
    Josiah Carlson
    Feb 12, 2004
  5. Charlie@CBFC
    Replies:
    1
    Views:
    346
    Hassan Davis
    Jan 11, 2007
Loading...

Share This Page