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

  • SEARCH
  • Home
  • 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 7563225
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T13:36:40+00:00 2026-05-30T13:36:40+00:00

i have a web service with signature : [WebMethod(EnableSession = true)] public Box FetchBox(string

  • 0

i have a web service with signature :

[WebMethod(EnableSession = true)]
public Box FetchBox(string boxId, string p1, string p2, string p3 )

i call this web service by a jquery ajax :

$.ajax({
  url: "/WS/Ajaxify.asmx/FetchBox",
  data: "{ 'boxId': '" + boxId + "' }",
  dataType: "json",
  type: "POST",
  contentType: "application/json; charset=utf-8"
});

i want to call FetchBox one time only with p1, later with p2 but not p1 and so on.

in many situations i need to call FetchBox method with any of p1 or p2 or p3 or …
parameter. i dont like to send all parameters because the system is plugin based and plugins do not know about others parameters.

optional parameter in c#4 does not working for a web service.

also params string[] parameters is not suitable here because i need to know the parameter name.

  • 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. Editorial Team
    Editorial Team
    2026-05-30T13:36:42+00:00Added an answer on May 30, 2026 at 1:36 pm

    You cannot send optional parameters to a SOAP web service. The SOAP protocol has no concept of optional parameters.

    Also, you should not be using ASMX services at all. That’s a legacy technology that shouldn’t be used for new development. WCF should be used instead.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a web method with a signature like this: public string[] ToUpper(string[] values)
When I call, the service's method, I have Web Service Exception happening which I
I have a web service that queries data from this json file, but I
Suppose I have an asmx web service at the following address: http://localhost/BudgetWeb/Service.asmx This web
I have a problem with axis2-client inside JAX-WS web service. This JAX-WS web service
I am trying to manually create the signature tag for a web service call.
i have implement a simple web service the method signature of web service is:
I have the following .NET web service with the following signature (IServices.cs): [OperationContract] [WebInvoke(Method
I have web service, which use integrated security in IIS. Now, I want to
I have a web-service that I will be deploying to dev, staging and production.

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.