on 08-08-2007 5:20 AM
Hi All,
Is there a solution for this problem? I can't see any method of Resource or InputStream which can serve the purpose. The bad part is if someone manually enters junk characters in the file name input field (w/o using Browse button), the browser only shows the circular in-progress image. One has to log off from portal. I fear if this endless loop continues, it may even bring down the J2EE server.
This is a very basic validation, and I can't deliver the application w/o adding this validation
Please help! Thanks in advance ...
Best Regards,
-AW
Hi Adam,
I am facing the same problem in my appliaction and the application goes for a toss.
If u hav found any solution to the above problem plz fwd it to me on email addr sudeep196@yahoo.co.in
Thnx,
Sudeep Sura
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Write a method as public void checkMandatory(java.lang.String fieldName).. within it write a logic to check for all invalid characters by iteration ... the moment if find a invalid charater highlight the field asking the user to input once again into the field.
The method would have coding like ... plz use your own logic to build it further.
public void checkMandatory(java.lang.String fieldName) {
WDMessageManager messageMgr = this.wdThis.wdGetAPI().getComponent().getMessageManager();
Object attributeValue = this.wdContext.currentContextElement().getAttributeValue(fieldName);
IWDAttributeInfo attributeInfo = this.wdContext.getNodeInfo().getAttribute(fieldName);
if (attributeValue instanceof String) {
if (((String) attributeValue).length() == 0) {
for (;;;) // logic to check the invalid characters
{
String fieldLabel = this.wdContext.getNodeInfo().getAttribute(fieldName).getSimpleType().getFieldLabel();
messageMgr.reportContextAttributeMessage(this.wdContext.currentContextElement(),
attributeInfo,
IMessageSimpleErrors.INVALID_INPUT,
new Object[] { fieldLabel },
true);
}
}
}
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
80 | |
9 | |
9 | |
7 | |
7 | |
6 | |
6 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.