You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by "R.Vijayaraghavan" <rv...@cdacnoida.in> on 2005/09/29 12:04:43 UTC
display checkbox with unique value using displaytag
Hello,
I am using displaytag to display a table of records. I am able to add a
checkbox as the first column using:
<display:column>
<html-el:checkbox property="checkbox_name" value="" />
</display:column>
The problem is that I am not able to set a unique value for each checkbox. I
am having a column in the recordset stored in a RowSetDynaClass that has the
unique values for all the checkboxes. I just need to assign them
appropriately.
regards,
vijay.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: [OT] display checkbox with unique value using displaytag
Posted by Laurie Harper <la...@holoweb.net>.
R.Vijayaraghavan wrote:
> Hello,
>
> I am using displaytag to display a table of records. I am able to add a
> checkbox as the first column using:
>
> <display:column>
> <html-el:checkbox property="checkbox_name" value="" />
> </display:column>
>
> The problem is that I am not able to set a unique value for each checkbox. I
> am having a column in the recordset stored in a RowSetDynaClass that has the
> unique values for all the checkboxes. I just need to assign them
> appropriately.
If your display:table is using the RowSetDynaClass as its data source,
you can set uid="row" in the table tag, then set value with
value="${row.someProperty}". See the displaytag documentation for
information on the uid attribute.
L.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
AW: display checkbox with unique value using displaytag
Posted by "R. Markham" <ma...@gmx.de>.
Hi Michael,
it is not German sense of humor, because I really didn't understand what
Vijay wanted. You are right it took me longer than 30 min to grasp the
usesage of table decorators. I would have preferred an example in the
documentation of display tag for the problem described by vijay.
Regards
Richard
-----Ursprüngliche Nachricht-----
Von: Michael Jouravlev [mailto:jmikus@gmail.com]
Gesendet: Donnerstag, 29. September 2005 17:55
An: Struts Users Mailing List
Betreff: Re: display checkbox with unique value using displaytag
German sense of humor, he-he. Vijay, have you already read DisplayTag
manual? It is a well-written document, you will need no more than 30
minutes to start with decorators.
Michael.
On 9/29/05, R. Markham <ma...@gmx.de> wrote:
> Hi Vijay,
>
> I am wondering why do you want unique value in a check box. A checkbox has
> the values true or false.
>
> Regards
>
> Richard
>
> -----Ursprüngliche Nachricht-----
> Von: R.Vijayaraghavan [mailto:rvijayaraghavan@cdacnoida.in]
> Gesendet: Donnerstag, 29. September 2005 12:05
> An: Struts Users Mailing List
> Betreff: display checkbox with unique value using displaytag
>
> Hello,
>
> I am using displaytag to display a table of records. I am able to add a
> checkbox as the first column using:
>
> <display:column>
> <html-el:checkbox property="checkbox_name" value="" />
> </display:column>
>
> The problem is that I am not able to set a unique value for each checkbox.
I
> am having a column in the recordset stored in a RowSetDynaClass that has
the
> unique values for all the checkboxes. I just need to assign them
> appropriately.
>
> regards,
> vijay.
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: display checkbox with unique value using displaytag
Posted by Michael Jouravlev <jm...@gmail.com>.
German sense of humor, he-he. Vijay, have you already read DisplayTag
manual? It is a well-written document, you will need no more than 30
minutes to start with decorators.
Michael.
On 9/29/05, R. Markham <ma...@gmx.de> wrote:
> Hi Vijay,
>
> I am wondering why do you want unique value in a check box. A checkbox has
> the values true or false.
>
> Regards
>
> Richard
>
> -----Ursprüngliche Nachricht-----
> Von: R.Vijayaraghavan [mailto:rvijayaraghavan@cdacnoida.in]
> Gesendet: Donnerstag, 29. September 2005 12:05
> An: Struts Users Mailing List
> Betreff: display checkbox with unique value using displaytag
>
> Hello,
>
> I am using displaytag to display a table of records. I am able to add a
> checkbox as the first column using:
>
> <display:column>
> <html-el:checkbox property="checkbox_name" value="" />
> </display:column>
>
> The problem is that I am not able to set a unique value for each checkbox. I
> am having a column in the recordset stored in a RowSetDynaClass that has the
> unique values for all the checkboxes. I just need to assign them
> appropriately.
>
> regards,
> vijay.
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
AW: AW: display checkbox with unique value using displaytag
Posted by "R. Markham" <ma...@gmx.de>.
I think you have to use a javascript function which is called when one of
the checkboxes is clicked. There is an example in the display tag
documentation how to produce row number. Look at the documentation about
implicit objects.
Regards
Richard
-----Ursprüngliche Nachricht-----
Von: vijay [mailto:vijaysubs@yahoo.com]
Gesendet: Donnerstag, 29. September 2005 18:29
An: Struts Users Mailing List
Betreff: Re: AW: display checkbox with unique value using displaytag
--- "R. Markham" <ma...@gmx.de> wrote:
> Hi Vijay,
>
> I am wondering why do you want unique value in a
> check box. A checkbox has
> the values true or false.
I actually want to see which all checkboxes have been
checked. The values are actually primary key values
which can uniquely identify all the items shown and
therefore the items selected.
Can it be done any other way. I want to create a
shopping cart kind of stuff where the items selected
are then add to the shopping cart. Is there any
written text to read which can guide me in doing this.
regards,
vijay.
__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
Re: AW: display checkbox with unique value using displaytag
Posted by vijay <vi...@yahoo.com>.
--- "R. Markham" <ma...@gmx.de> wrote:
> Hi Vijay,
>
> I am wondering why do you want unique value in a
> check box. A checkbox has
> the values true or false.
I actually want to see which all checkboxes have been
checked. The values are actually primary key values
which can uniquely identify all the items shown and
therefore the items selected.
Can it be done any other way. I want to create a
shopping cart kind of stuff where the items selected
are then add to the shopping cart. Is there any
written text to read which can guide me in doing this.
regards,
vijay.
__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
AW: display checkbox with unique value using displaytag
Posted by "R. Markham" <ma...@gmx.de>.
Hi Vijay,
I am wondering why do you want unique value in a check box. A checkbox has
the values true or false.
Regards
Richard
-----Ursprüngliche Nachricht-----
Von: R.Vijayaraghavan [mailto:rvijayaraghavan@cdacnoida.in]
Gesendet: Donnerstag, 29. September 2005 12:05
An: Struts Users Mailing List
Betreff: display checkbox with unique value using displaytag
Hello,
I am using displaytag to display a table of records. I am able to add a
checkbox as the first column using:
<display:column>
<html-el:checkbox property="checkbox_name" value="" />
</display:column>
The problem is that I am not able to set a unique value for each checkbox. I
am having a column in the recordset stored in a RowSetDynaClass that has the
unique values for all the checkboxes. I just need to assign them
appropriately.
regards,
vijay.
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org