on 12-10-2007 8:11 AM
hi all,
currently i take a email receive view from the Email Interactive Form Tutorial
but currently i have some problem with the subject get... function
in the tutorial it teach this
<b>if (message<i>.getSubject().equals("Travel Request Form")) {</b>
but then it only get email with the subject "Travel Request Form" but if i want to display email with the subject "Travel" or "Request" or "Form" in other way also can say like that "TravelRequestForm"
and the code i code is this
<b>if (message<i>.getSubject().matches("
Travel") || message<i>.getSubject().matches("
Request") || message<i>.getSubject().matches("
Form") || message<i>.getSubject().equals("Travel Request Form")) {</b>
but if like that code.. i can display if the subject is travel or request or form but if the subject is travel request data it is not able to display.
hope you all can advise me how to change this code to get.. subject with Travel Request Data? or even the subject with Travel Request
Hi,
You can try this:
int tIndex = message.indexOf("Travel");
int rIndex = message.indexOf("Request");
int fIndex = message.indexOf("Form");
if(tIndex != -1 || rIndex != -1 || fIndex != -1){
//process...
}
Regards,
Satyajit.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.