asp.net - Use javascript variable into inlined code -


How can I call a pure method inline code using a javascript variable? My code looks like this:

 for  (var i = 0; i & lt; number entry; i ++) {var result = & lt;% # GetFilterTagURL (myArray [i ]. Value, inaccurate)%> // work with results}   

This block is inside a Javascript block; GetFilterTagURLType AAt Is the method and I want to give variable myArray [i] .Value as the first parameter.

Any thoughts? Update: All your answers are helpful. I think, as you say, what I need to do is to make me a web service.

You will not be able to complete it like this because the & lt; % #% & Gt; tag is used.

An approach however will create a webservice and call it from your javascript. You can call GetFilterTagURL to call you inside your webservice and use the results in your Javascript.

See for more information.

Comments

Popular posts from this blog

qt - switch/case statement in C++ with a QString type -

python - sqlite3.OperationalError: near "REFERENCES": syntax error - foreign key creating -

Python's equivalent for Ruby's define_method? -