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. Server Side Calling Method From Javascript

Server Side Calling Method From Javascript

Scheduled Pinned Locked Moved Web Development
javascriptsysadminquestion
2 Posts 2 Posters 1 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.
  • K Offline
    K Offline
    khKamel
    wrote on last edited by
    #1

    Hello, When i want to call a server side from javascript i used to use the alert('<% MethodName() %>') which returns a specific string. Now i want to apply this in Jscript.js File which can't be done. My question is how could i use that type method calling from a js file. Please note that the method is found a another place such as (Master Page) Many Thanks

    M 1 Reply Last reply
    0
    • K khKamel

      Hello, When i want to call a server side from javascript i used to use the alert('<% MethodName() %>') which returns a specific string. Now i want to apply this in Jscript.js File which can't be done. My question is how could i use that type method calling from a js file. Please note that the method is found a another place such as (Master Page) Many Thanks

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

      By using <%= MethodName %> you are not really using JavaScript to call the server, this is done by ASP.NET while processing the page, this is why it only works in an ASP.NET page and not from an external file.

      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