Solved

Options Buttons Misbehaving....

Posted on 2004-10-12
11
162 Views
Last Modified: 2010-04-25
I have a form created with Dreamweaver that has standard Yes/No option buttons that are allowing the user to choose both options.  I've not encountered this before.  Anyone know how to fix it?
0
Comment
Question by:johnson00
  • 4
  • 3
  • 3
  • +1
11 Comments
 
LVL 14

Expert Comment

by:Esopo
ID: 12292004
What do you call standard Yes/No buttons? Would you mind to post some code?
0
 
LVL 49

Expert Comment

by:Ryan Chong
ID: 12294390
try set the Yes/No option buttons with same name?
0
 
LVL 2

Author Comment

by:johnson00
ID: 12297781
They have the same name, and both are currently set to return True as a value, as when I returned False as a value to my Access database, the report did not pick up the "false" and mark that option button.  Does that make sense?
0
 
LVL 2

Author Comment

by:johnson00
ID: 12301326
<INPUT TYPE="radio" NAME="SCEmployedY" VALUE="TRUE">
        Yes
        <INPUT TYPE="radio" NAME="SCEmployedN" VALUE="TRUE">
        No

I guess they are named differently.  I had difficulty getting them to return to a database correctly when they were named the same.  I need this value to correctly populate a radio button in an access report, which is why I split them up.  How SHOULD I have done this?
0
 
LVL 2

Author Comment

by:johnson00
ID: 12301330
Points increased
0
Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

 
LVL 14

Expert Comment

by:Esopo
ID: 12303154
I think I understand what you want. First of all, how do you spect different returns if they both have TRUE as the value?

Give the radio options the same name and different values, exmpl:

 <INPUT TYPE="radio" NAME="radio1" VALUE="1"> Yes
 <INPUT TYPE="radio" NAME="radio1" VALUE="0"> No

Now, in ASP chech for the variable ("radio1" in this case) to see which was chosen (either 1 or 0).

Basically the "radio group" will allow for multiple choice answers and only pass to your ASP the one chosen. You group them by assigning the same name to every element but different values. You should receive it as a single variable (radio1) with a single value (either 1 or 0 for this case).

Is this helping you?
0
 
LVL 14

Expert Comment

by:Esopo
ID: 12303178
BTW: this should work for you but you could use a dropdown list aswell.

These are great to play around with the code:

http://www.w3schools.com/html/tryit.asp?filename=tryhtml_radio

http://www.w3schools.com/html/tryit.asp?filename=tryhtml_select2
0
 
LVL 49

Expert Comment

by:Ryan Chong
ID: 12304454
>><INPUT TYPE="radio" NAME="SCEmployedY" VALUE="TRUE">
        Yes
        <INPUT TYPE="radio" NAME="SCEmployedN" VALUE="TRUE">
        No

ya, try as:

<INPUT TYPE="radio" NAME="SCEmployed" VALUE="TRUE">
        Yes
        <INPUT TYPE="radio" NAME="SCEmployed" VALUE="FALSE">
        No
0
 
LVL 19

Accepted Solution

by:
webwoman earned 250 total points
ID: 12310287
If you're using an Access database, and you have the field set as a yes/no field, you should use -1 for the true value and 0 for the false.

That's the values Access is looking for. You can't use a string ("TRUE" "FALSE") because that's NOT a text field.
0
 
LVL 49

Expert Comment

by:Ryan Chong
ID: 12310439
We can still put the value as "true" or "false", as the SQL statement to be executed is just a string, and the statement will recognize the value of "true" or "false", as it's a boolean value. Of course using of "-1" and "0" that webwoman mentioned will always works as well.

cheers ;-)
0
 
LVL 2

Author Comment

by:johnson00
ID: 12312715
webwoman,

that is exactly the information I was looking for.  Thanks!
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

For those who don't know, Adobe Dreamweaver is a popular commercial web editor that enables you to design, build and manage complex websites. The editor is a WYSIWYG (What You See Is What You Get) web editor, which means that you can create your web…
This article is very specific and is only intended to help if you are installing Dreamweaver 8 in a Windows 7 environment with Office 2007 installed.   I'm not sure why Microsoft tends to release OS' that should not be released but they do.  Windows…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now