Calling a function

Results 1 to 2 of 2

Thread: Calling a function

  1. #1
    Join Date
    Dec 1969

    Default Calling a function

    How can you call a function when a user clicks on a button?<BR><BR>Example: User clicks on a button and I want to call a function to calculate a formula on the same page?<BR><BR>Thanks

  2. #2
    MikeD Guest

    Default RE: Calling a function

    Your HTML for the button element should look like this:<BR>&#060;input type="button" name="..." value="..." <BR> onclick="MyFunction()" &#062;<BR><BR>Your client side script can have the function MyFunction;<BR><BR>function MyFunction(){<BR> // do something here<BR>}<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts