lijun wang

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

Recent posts by lijun wang

Hi, I have JSF code :
<h:outputText styleClass="outputText" id="text1" value="#{testBean.f}">
<f:convertNumber locale="fr" type="currency" currencySymbol="$"/>
</h:outputText>

which testBean.f = 9.99

I think it should display 9,99$(french format), but it is not, anybody know the reason?
Thanks,
18 years ago
JSF
How to count the execution time of my select statement?
Thanks.
can i bind an UIData - myUIData (in pagecode) to a arraylist which is the datasource of a datatable which also bind to the myUIData in jsp.
18 years ago
JSF
Can I invoke portlet doview() in JSF pagecode?
Thanks
18 years ago
JSF
I'm using JSF, so there is no body tag, but f:view instead
Thanks
is there a onload()(javascript) method when I load JSP file?
changePrice( getpriceTotals());
I have this method in the changprice.java(pagecode),getpriceTotals() get the totlas price bean which is a managed bean from session scpoe, this bean also bind to text40 (a HtmlOutputText)in changeprice.jsp.
my question is , when I change the value of text40, how can I get the right value through getpriceTotals(), because I always get the old value.
Thanks
18 years ago
JSF
can anybody explain why this code print "Wed Mar 01 00:00:00 MST 2006" instead of throws a ParseException?

-----------------------------------------------
public class test {
private void testDate(){
SimpleDateFormat dateFormatter = new SimpleDateFormat("yyyyMMdd");
try {
Date invoiceDate = dateFormatter.parse("2006031f");
System.out.println(invoiceDate);
} catch (ParseException pe) {
pe.printStackTrace();
}
}
public static void main(String[] args){
test test1 = new test();
test1.testDate();
}
}
--------------------------------------------------
18 years ago
DateFormat formatter = new SimpleDateFormat("yyyyMMdd");
Date aTrueDate = null;
try {
aTrueDate = formatter.parse("2006050f");
} catch (ParseException e) {
e.printStackTrace();
}

I tried this code, but it didn't throw a ParseException, it display 2006/05/01, and formatter.parse("200605ff") throw a ParseException.
18 years ago
so thorw exception to high level is to keep the trace when I debug the code, is that right?
thanks.
do I need throw the exception which I catched in DAO to high level, like facade? if the answer is yes, why?
Thanks.
I install a jre5 and set it as RAD dfault jre, but I still can't import java.util.regex, and String has no matches method, why???
Thanks.
18 years ago
I use RAD 6.0.1, is its java version 1.3, I can't believe, how to check the java version of RAD?
18 years ago
I tried to use this:
boolean b = myString.matches("\\d+");
but has the error in RAD:
The method matches(String) is undefined for the type String

WHY? I checked java API, string has this method!
18 years ago
how to validate a string like "20060503" is DATE?how to validate this string are all number, not charactor?
Thanks.
18 years ago