Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

from vbscript to javascript to vbscript HELP!!

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
0
0
have a unsolvable problem
maybe you can figure it out
well here it goes
i am writing in vbscript and set a variable in vbscript
then i call a javascript from inside my vbscript
which works fine but my problem is i need to use that vbscript variable in the javascript function.
Here is how i call it
Response.write &quot;<a href=&quot;&quot;#&quot;&quot; onclick= &quot;&quot;javascript:download_multiple_files(counterNameNormal)&quot;&quot;><IMG SRC=&quot;&quot;../images/check.gif&quot;&quot;></a>&quot;

where counterNameNormal is the vbscript variable i am trying to use.
Please Help!!!!!!!!
 
As in Response.Write you just write a String or other variables, you can split it:

Code:
Response.write(&quot;<a href=&quot;&quot;#&quot;&quot; onclick= &quot;&quot;javascript:download_multiple_files(&quot;)
Response.write(counterNameNormal)
Response.write(&quot;)&quot;&quot;><IMG SRC=&quot;&quot;../images/check.gif&quot;&quot;></a>&quot;)

You could also contatenate it using & (like the following):

Code:
Response.write(&quot;variable is: &quot; & var & &quot; - great, isn't it?&quot;)

Hope this helps...
 
Ah, something else: Please post something like this in the JavaScript or vbScript forum next time...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top