🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: chile.comp.programacion
Article #655

Re: Radio en Grilla

#655
From: AADR
Date: Wed, 09 Jan 2008 13:21
39 lines
2092 bytes
Pintamono escribi�:
> Que tal, un compa�ero de trabajo tiene el siguiente problema...
> 
> En una grilla debe ingresar tres radio button, el usuario solo debe 
> seleccionar uno, hasta ahi todo bien, el problema es que debe existir en 
> la cabecera de la grilla un checkbox que permita seleccionar por defecto 
>   el primer radio de todas las row de la grilla, como los radio se 
> llaman igual el proceso siempre deja seleccionado el tercero cuando en 
> realidad deberia seleccionar el primero...
> 
> algo asi:
> 
> DATOS | O Seleccionar Opcion 1|
> dato 1 | O | O | O |
> dato 2 | O | O | O |
> dato 3 | O | O | O |
> 
> si pincha O de la cabecera deberia seleccionar Op1 para dato 1, 2 y 3...
> 
> Es ASP .NET (C#)
> 
> Gracias.
> 

Codigo javascript
/**
objeto: referencia al radiobutton.
valor: true o false
*/
function MarcaTodos(objeto,valor) {
	var x=0;
	if (objeto!=null){
		if (objeto.length){
		  for (x=0;x<objeto.length;x++)
		   objeto[x].checked=valor;
		}else
		   objeto.checked=valor;
	}
}
Technical Details
Message-ID: <4784CA42.6080805@gmail.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!news.kjsl.com!news.nivel5.cl!news2.ifxnw.cl!news.tie.cl!not-for-mail
References: <559d3d8bf6afee21fed3788a5e2aac05$1@usenet.no-ip.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 1593cb,50ddf35d05069670
X-Google-Attributes: gid1593cb,public,usenet
X-Google-Language: SPANISH,ASCII
Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!news.glorb.com!news.kjsl.com!news.nivel5.cl!news2.ifxnw.cl!news.tie.cl!not-for-mail
From: AADR <alediazrub@gmail.com>
Newsgroups: chile.comp.programacion
Subject: Re: Radio en Grilla
Date: Wed, 09 Jan 2008 10:21:06 -0300
Organization: Telefonica Internet Empresa
Lines: 39
Message-ID: <4784CA42.6080805@gmail.com>
References: <559d3d8bf6afee21fed3788a5e2aac05$1@usenet.no-ip.com>
NNTP-Posting-Host: 200.68.49.68
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: jagger.tie.cl 1199884902 15218 200.68.49.68 (9 Jan 2008 13:21:42 GMT)
X-Complaints-To: news@jagger.tie.cl
NNTP-Posting-Date: Wed, 9 Jan 2008 13:21:42 +0000 (UTC)
To: Pintamono <pintamono@NoMandeWeas.kk>
User-Agent: Thunderbird 2.0.0.9 (Windows/20071031)
In-Reply-To: <559d3d8bf6afee21fed3788a5e2aac05$1@usenet.no-ip.com>