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 6687421
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T05:17:13+00:00 2026-05-26T05:17:13+00:00

I built a simple asp.net web service. It works when I put the URL

  • 0

I built a simple asp.net web service. It works when I put the URL of the service: I see the default Microsoft page and the link to the web method. I enter the parameters and get the expected result.

However, when I use $.ajax to call the service, all I get is a 500 error back.
For the url parameter, I enter this:

url: "../WebServices/MyService.asmx/MyMethod",

Could that be it?

1) I put a break point and it triggers when I run the service from the browser but it doesn’t trigger when called from the jquery function.

2) Is there something I need to tweak in the web.config file? What does the following mean? It’s what I see when I access the service from the browser.

3) Also, I’m sending the data in the format of json when I’m using the jquery way; do I need to change something in the .cs file?

<string xmlns="http://tempuri.org/">

What could be going on?

Thanks for your suggestions.

  • 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-26T05:17:13+00:00Added an answer on May 26, 2026 at 5:17 am

    Ok, if someone’s bumping on this issue and finds this page, one of the things to do to make the web service work is to add this:

    [System.Web.Script.Services.ScriptService]
    

    add it just before your line

    public class ServiceName : System.Web.Services.WebService {
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm an ASP.NET web part novice. I've built a few simple ones using only
I have a simple web app built in asp.net webforms c# where and how
I'm building a traditional ASP.NET Web Service -- the style built using asmx. It's
I tried implementing a simple web service into an asp.net application using the tutorial
I have an asp.net web page with a simple search text box that returns
i write a simple webservice code in asp.net when i build the service and
So in my simple learning website, I use the built in ASP.NET authentication system.
I just built a asp.net 2.0 web site. Now I need add REST web
We have a web site built as an 'ASP.NET Website' type project, rather than
I've got a simple web application using ASP.NET MVC3 and Ninject.Web.MVC (the MVC3 version).

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.