File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes HTML, CSS and JavaScript and the fly likes Problem in calling javascript function Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Problem in calling javascript function" Watch "Problem in calling javascript function" New topic

Problem in calling javascript function

subhasish nag
Ranch Hand

Joined: Apr 25, 2008
Posts: 101
Hi Ranchers,
I have a problem.
want to call a function to set a jsp field dynamically
the function is
I am unable to call the function as I 'm unable to pass the right argumenty.

Can anybody pl guide how to call the function properly and set the value for the field

Thanks,<br />Subhasish
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63862

A couple of things.

Firstly, this is an HTML forum, not a Struts forum. Posting code with Struts tags in it isn't a great idea as most people won't know what they mean. Please show only the real HTML code.

Your code also has a lot of formatting problems that makes it hard to read.

Secondly, please use real words when posting to the forums. Abbreviations such as "pl" in place of "please" only serve to make your posts more difficult to read and less likely to generate useful responses.

Please read this for more information.

JavaRanch sheriff

[Asking smart questions] [About Bear] [Books by Bear]
James Ward
Ranch Hand

Joined: Apr 27, 2003
Posts: 263
getCertificateNo - from your html code, we do not see any invocation of this function. You said you are not able to call this function with correct arguments; can you show how you are calling it.
Gavi jadz Grandea

Joined: Sep 11, 2009
Posts: 17
I think onchange() should call a javascript function (probably the one you posted:
onchange="getCertificateNo(<%=var%>)" ).

And you might want to explain/show more for us to understand better.

Eric Pascarello

Joined: Nov 08, 2001
Posts: 15385
Seeing serverside markup does not help, we need to see examples on what gets rendered.

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63862

Gavi jadz Grandea,

Please be sure to use code tags to display code in your posts rather than green text (which is hard to see against the tab background on many monitors).
I agree. Here's the link:
subject: Problem in calling javascript function
jQuery in Action, 3rd edition