1 Replies - 683 Views - Last Post: 17 October 2012 - 03:47 PM Rate Topic: -----

#1 w00t1337  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 5
  • Joined: 22-March 10

VBscript help

Posted 09 October 2012 - 10:56 AM

Sorry guys, hopefully this is the correct forum to place this. I am having trouble trying to take data from an HTML text box in a form. Would this be the correct way to declare a variable with a value from the form?

Dim LineOne = document.myForm.firstLine.value

Also, I need to be able to output text to another HTML text box in the same form. Would this work for taking two different strings, concatenating them, and outputting them to another text field? (I already declared LineOne and LineTwo similar to what I showed above)

Dim TheString = document.myForm.showanswer.value
theString = LineOne + LineTwo

Nothing seems to show up in the third text box when I click submit.

Is This A Good Question/Topic? 0
  • +

Replies To: VBscript help

#2 BobRodes  Icon User is offline

  • Lovable Curmudgeon
  • member icon

Reputation: 594
  • View blog
  • Posts: 3,055
  • Joined: 19-May 09

Re: VBscript help

Posted 17 October 2012 - 03:47 PM

Have a look at this and see if you can piece it together. If firstline is one of your elements in your form, then you can't do it that way. You have to refer to the elements collection.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1