Alexander Bell

Greenhorn
+ Follow
since Mar 31, 2008
Merit badge: grant badges
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Alexander Bell

Ok, I understand. It sounds plausible with your description

Thanks Dave
There is a task which I don't unterstand



Possible Code
A) Object x = t.find(123, "456");
B) int x = t.find(123, new Double(456));
C) int x = t.find(123, new Integer(456));
D) int x = (int)t.find(new Double(123), new Double(456));

In my opinion C and D are valid.
In fact A and C are valid.

So, why is A correct?

I thought you define with the first parameter the type for the metho.
So, in C the type is defined by the first parameter -> int therefore the second parameter must be an Integer as well.
For the same reason, I thougt D was correct as well.

Can anyone explain that?

mfg alex
Hi,

i don't try that with an array of selectItems.

you can try to use a map (e.g. a HashMap) to deliver the values.
The keys are the lables on the HTML-Page an the values are the values for the bean-property.

You should also define the attribute "value" in the selectOneMenu-Tag.

mfg alex
16 years ago
JSF
Hi,

you can solve this problem by using Ajax.

For instance you can use the Ajax-JSF-Solutino from J4Fry.
http://www.j4fry.org/jsfAjax.shtml

On every onKeyDown-event you initiate an ajax-request. You have got an select-List with many Items that are updated by the ajax-util. With the attributes "preJSFunction" and "postJSFunction" you can show and hide the select-box.

But there are any other components which have auto-suggestions e.g. ice-faces.

mfg alex
16 years ago
JSF
Hi,

there is a nice book which describes the development of jsf-components:
JavaServer Faces. The Complete Reference (Complete Reference Series) - written by Chris Schalk, Ed Burns

There is also a nice artivel on the ibm website as well: http://www.ibm.com/developerworks/library/j-jsf4/

Maybe Facelets are the better choice cauz you can use the existing standard-jsf-components to build you own "component". So it's a lot easier to develop "components" with facelets.
Have a look at https://facelets.dev.java.net/ (the documentation is very good)

mfg alex
16 years ago
JSF
Hi,

there is a nice solution on the glassfish page: https://javaserverfaces.dev.java.net/sandbox/components/prettyUrl.html


You can also use the "onLoad" Tag from http://www.j4fry.org
In the triggered action you can get your GET-parameters from the httpRequest-parametersMap.
http://www.j4fry.org/jsfOnLoad.shtml

mfg Alex

------------------
Visit http://www.j4fry.org
16 years ago
JSF
Hi,

you can use the "columnClasses" attribute of the h:dataTable Tag.
You can specify for every column one style-class.

E.g


You can specify styles for the rows as well with the "rowClasses"-Attribute

See more Examples with JSF-Datatables on http://www.j4fry.org/J4Fry_Quick_Setup_Tomcat_MyFaces_Hibernate/index.faces


---------------------
Visit http://www.j4fry.org
16 years ago
JSF