Sending text to my webmethod returns exception

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • @rturo

    #1

    Sending text to my webmethod returns exception

    I have a webservice running and I have a method with a string parameter.
    The method is quering an xml file but i need to enter the exact letter case
    in the string to get the right reult otherwise is returning me and Exception.

    for example this xml...

    <location id="123">Financ e</location>
    <location id="124">Operat ions</location>

    if the parameter i send is "finance" i'll get an exception. It will only let
    me enter "Finance" to get the right Response.

    Please help me
  • Jay Kudecha

    #2
    RE: Sending text to my webmethod returns exception


    Hello @rturo,

    If you are using the xml file, it is case sensitive only, and allows the
    comparisions of the attributes or elements of xml file with case sensitivity.
    If you wish to compare the strings from client app with xml file without
    case sensitivity then You can convert the strings to upper or lower case in
    the webservice only and then go on with the function logic.
    Also, if you don't convert the string to lower or upper case, then also it
    does not throw any exception to you, there is a possibility that some bug
    might have been introduced in the code only.

    Hope this helps you, let me know in case of further assistance.

    Jay Kudecha.

    "@rturo" wrote:
    I have a webservice running and I have a method with a string parameter.
    The method is quering an xml file but i need to enter the exact letter case
    in the string to get the right reult otherwise is returning me and Exception.
    >
    for example this xml...
    >
    <location id="123">Financ e</location>
    <location id="124">Operat ions</location>
    >
    if the parameter i send is "finance" i'll get an exception. It will only let
    me enter "Finance" to get the right Response.
    >
    Please help me

    Comment

    Working...