logo-dw

Go Back   Dreamweaver Club Forums > Hand Coders Forum > Javascript and JS frameworks
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 01-23-2010, 06:37 PM   #1
GreenBill
 
Join Date: Jan 2010
Posts: 4
Default If and function?

Is there anyway to have an if and function or something similar?

What I'm trying to do is have the if function only show positive if textbox1=42 and textbox2=97. Is there any simple way to do this?
GreenBill is offline   Reply With Quote
Old 01-24-2010, 12:24 AM   #2
GreenBill
 
Join Date: Jan 2010
Posts: 4
Default

I figured it out, for those who are curious the way to do it is
Code:
if(condition1 && condition2)
{
function
}
Or in my example's case
Code:
if(form1.textbox1.value=="42" && form1.textbox2.value=="97")
{
form1.textbox3.value=("103")}
GreenBill is offline   Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:03 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com