Re: Problem with hidden String[] object

2006-10-23 Thread Laurie Harper
Yep, you can't pass a String array as a single input/hidden, unless you're willing to handle marshalling it to/from a single-string representation. Far easier would be to expose the array as an index property and serialize it to/from the view using a set of hidden inputs. L. [1] http://struts

RE: Problem with hidden String[] object

2006-10-20 Thread Strachan, Paul
To populate the string array your http request would take the structure: name=value1&name=value2&name=value3 etc where you have a java.lang.String[] name; property on your form. So there are many ways to do this in html, with Struts tags (eg populated from form) you could try: Not

Re: Problem with hidden String[] object

2006-10-20 Thread Sócrates Medina
Instead of string array, I would do it with a object that implement interator interface, like ArrayList. If you have an array list, you can add indeterminate numbers of objtects like string one I hope, this could help you...I'm a new struts developer...only weeks, but i'm pretty sure ths

Re: Problem with hidden String[] object

2006-10-20 Thread Anet
Hi; Thank very much for your help, but my string[] object filled dynamic.I don't know its size at first. and I don't need its data on my form, I just need them to pass with form when the form is submitted. also your solution can help me. just I want to know something. I saw in a document that

Re: Problem with hidden String[] object

2006-10-20 Thread WongTseng王曾
Maybe you can make your String[] Object a indexed attribute of your formbean. Then use html:hidden: something like this below: Class YourFormBean extends ActionForm{ String[] aaas = new String[5]; public String getAaa(int index){ return aaas[index]; } publi