Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Web Services

Web Services

Scheduled Pinned Locked Moved ASP.NET
csharpasp-netdatabasewcfhelp
6 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • I Offline
    I Offline
    ishwarya mahadevan
    wrote on last edited by
    #1

    HI, I m creating a login page in asp.net..i need to use web service method and write stored procedure to check if user name and pwd are correct..if its right then need to direct the user to another page else display an error...since response.redirect wont work in web service can u suggest how to go about it???

    S M 2 Replies Last reply
    0
    • I ishwarya mahadevan

      HI, I m creating a login page in asp.net..i need to use web service method and write stored procedure to check if user name and pwd are correct..if its right then need to direct the user to another page else display an error...since response.redirect wont work in web service can u suggest how to go about it???

      S Offline
      S Offline
      sashidhar
      wrote on last edited by
      #2

      Get The Status from web service like true or false and redirect from ur code..! But Why would you use webservice to check if user name and pwd are correct.You can use normal method..!

      LatestArticle :Log4Net Why Do Some People Forget To Mark as Answer .If It Helps.

      I 1 Reply Last reply
      0
      • S sashidhar

        Get The Status from web service like true or false and redirect from ur code..! But Why would you use webservice to check if user name and pwd are correct.You can use normal method..!

        LatestArticle :Log4Net Why Do Some People Forget To Mark as Answer .If It Helps.

        I Offline
        I Offline
        ishwarya mahadevan
        wrote on last edited by
        #3

        How do we get the status???? Ya i know...but i m asked to use the webservice method for everything.

        S M 2 Replies Last reply
        0
        • I ishwarya mahadevan

          How do we get the status???? Ya i know...but i m asked to use the webservice method for everything.

          S Offline
          S Offline
          sashidhar
          wrote on last edited by
          #4

          Check this Code..!

          [WebMethod]
          public bool Name()
          {
          If (Condition)
          {
          return true;
          }
          else return false;
          }

          In your Code..!

                  //In Your .asp.cs page
                  localhost.Service1 svc = new Service1();
                  bool ssd=  svc.Name();
                 if(ssd)
                 Response.Redirect("YourPage.aspx)
          

          First Try To learn abt the webservices usuage in asp.net Calling Web Service using ASP.NET[^]

          LatestArticle :Log4Net Why Do Some People Forget To Mark as Answer .If It Helps.

          1 Reply Last reply
          0
          • I ishwarya mahadevan

            How do we get the status???? Ya i know...but i m asked to use the webservice method for everything.

            M Offline
            M Offline
            mdrizwan_1
            wrote on last edited by
            #5

            Check for web service status (i.e.,What is it return type), according to it process your code.

            1 Reply Last reply
            0
            • I ishwarya mahadevan

              HI, I m creating a login page in asp.net..i need to use web service method and write stored procedure to check if user name and pwd are correct..if its right then need to direct the user to another page else display an error...since response.redirect wont work in web service can u suggest how to go about it???

              M Offline
              M Offline
              mrMercury
              wrote on last edited by
              #6

              Are you calling the WebService from the client? If so then you’ll need to check the result in your success callback, if the user is validated then you can redirect using JavaScript window.location.assign("MyNewPage.htm")

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups