aamchi mumbai

Greenhorn
+ Follow
since Mar 04, 2005
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by aamchi mumbai

Hi,

i have report data in arraylist

ArrayList al = new ArrayList();
HashMap hm = new HashMap();

hm.add("01/01/2005");
hm.add("one");
hm.add("two");
hm.add("test");

al.add(hm);

hm=new HashMap();
hm.add("01/01/2005");
hm.add("three");
hm.add("four");
hm.add("test");

al.add(hm);

hm=new HasmMap();
hm.add("01/02/2005");
hm.add("five");
hm.add("six");
hm.add("test");

al.add(hm);

now i want to display this report datewise

01/01/2005
one two
three four
01/02/2005
five six


Is there any way that i can use struts tag and display in this format or i have to use scriptlet only. i know how to iterate but i dont how to store date to compare...

Thanks in Advance
19 years ago
Thanks for reply.....my problem solved
19 years ago
Hi

I have a report page which show list of item. User can click on item and see detail page.
But now if user click browser back button i am getting warning page saying that
Warning: Page has Expired The page you requested was created using information you submitted in a form. This page is no longer available. As a security precaution, Internet Explorer does not automatically resubmit your information for you.

is there any way to display previous list page? if i change post method to "GET" it is working but i dont want to do that.

Thanks in Advance
19 years ago
Anyone knows answer for this
19 years ago

Originally posted by Vicky Pandya:
use logic:equal to compare your values.



what if i dont know the value i just know the index number
19 years ago
Hi,

i have value in vector.
Vector outV = new Vector();
Vector inV = new Vector();

inv.add("01/01/2005");
inv.add("one");
inv.add("two");
inv.add("test");

outv.add(inv);

inv=new Vector();
inv.add("01/01/2005");
inv.add("three");
inv.add("four");
inv.add("test");

outv.add(inv);

inv=new Vector();
inv.add("01/02/2005");
inv.add("five");
inv.add("six");
inv.add("test");

outv.add(inv);


now i want to diplay this value in jsp like this,

01/01/2005
one two
three four
01/02/2005
five six

Please help i am stuck here.....thank in advance
19 years ago
i got the answer

using this i can do that

logic:match name="data" property="name" value="<%=toCompare%>" location="start">
Matching......
</logic:match>
19 years ago
Hi,

<bean define id="toCompare" value="JAVA"/>

<logic:match name="data" property="name" value="" location="start">
Matching......
</logic:match>

i want to match name property with "JAVA" value but i dont want to write value="JAVA". is there any way i can compare with variable value. in this case can i specify compare with "toCompare" variable.

Thanks,
19 years ago
Hi,

<bean efine id=[B]"toCompare"[B] value="JAVA"/>

<logic:match name="data" property="name" value=[B]""[B] location="start">
Matching......
</logic:match>

i want to match name property with "JAVA" value but i dont want to write value="JAVA". is there any way i can compare with variable value. in this case can i specify compare with "toCompare" variable.

Thanks,
19 years ago
Hi,

Suppose i have vector
v = new Vector();

v.add("one");
v.add("two");
v.add("three");
v.add("four");

Now i want to display only value "one" and "three". how can i write struts tag do display that value?

is there any documentation where i can get all this information?

Again
Thanks in advance
19 years ago
Thanks it is working now
19 years ago

Originally posted by Junilu Lacar:
In what way is it not working? Is it throwing an exception or is it just not displaying in the format that you want?



its not throwing any exception but it is not displaying that value.
19 years ago
Hi,

i have hashmap which contain following values

HashMap hm = new HashMap();
hm.put("id", "111");
hm.put("name", "Java");
hh.put("date",new java.util.Date());

request.setAttribute("data", hm);

in jsp

<bean:write name="data" property="id"/> <!-- Working Fine -->
<bean:write name="data" property="name"/> <!-- Working Fine -->
<bean:write name="data" property="date"/> <!-- THIS IS NOT WORKING -->

i am stuck here.

Thanks in Advance
19 years ago
Hi,

i have hasmap like this

HashMap hm = new HashMap();
hm.put("id", "101");
hm.put("name", "java");

request.setAttribute("data", hm);

now i want use struts tag to display value of ID key. is there any way i can pass KEY and i can get value for that key. i dont wat to iterate.

Thanks in advance
19 years ago