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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T12:09:16+00:00 2026-06-15T12:09:16+00:00

I have to call a server side method GetMSG using jQuery and that server

  • 0

I have to call a server side method GetMSG using jQuery and that server side method

[WebMethod()]
public string GetMSG() {
    if(condition) {
        return 'MSG'
    } else {
        return ''  
    }
}

Now using that msgI have to show alert. How to use return msg and display alert in jQuery.

  • 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-06-15T12:09:18+00:00Added an answer on June 15, 2026 at 12:09 pm

    Do you need the jQuery code to perform the Ajax call and display the return? If yes you could go with something like this:

    $.ajax({
        url: urlOfThePage + "GetMSG",
        type: "get",
        success: function (response, textStatus, jqXHR) {
            alert(response);
        },
        error: function (jqXHR, textStatus, errorThrown) {
        },
        complete: function () {
        }
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a simple WCF service that I call server side from code behind
Can I use PageMethods in .net1.1?I have to call a server side method call
Does anyone know how to call a server-side c# method using javascript? What i
I wanted to know if you can call server side method using JavaScript or
I have a class at server-side like this: public class Address { public Address(string
I need to get array of images that have to call from server and
I have an Activity that makes a remote server call and tries to populate
I have a GWT app that makes an RPC call to a server to
I have come up with the following code to call a webservice using client/server
I'm using SQL Server 2005 I have a user. We'll call him User1. He

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.