on 11-19-2007 6:16 AM
Dear All,
I am doing one File-XI-RFC scenario in which user is sending me the file with some delivery nos (VBELN) in it and I am sending those all delivery nos to my RFC in R/3.
Now I want one conition to be put that if any delivery no is of less than 10 characters than that delivery no should not be sent to RFC rest the remaining will be processed to RFC.
I have put one UDF for this whose code is as follows:
int len = a.length();
if (len == 10)
{
int b=1;
b = (1/len);
}
return a;
But this code is not working. Please guide me how to solve this problem.
Regards,
N.Jain
HI,
Input is A : Delivery No take all the delivery no in one context.
for(i=0;i<A.length;i++)
{
int b= Integer.parseInt(A<i>); it will remove all the leading zeros if it has any.
int j=(new Integer(b).toString().length()); count the lenght of the Del no.
if(j>10)
{
result.addValue(A(i));
}
else
{
result.addValue("null"); will not send anything.
}
}
Thanks and Regards,
Chirag gohil
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I used the following code and my problem is solved:
int len = a.length();
if (len==10)
{
return a;
}
else
{
len =0;
int b=1;
b = (1/len);
return a;
}
Thanks for your valuable replies.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
First of all , can you please close the thread or mark it answered (the Surpassing zero problem) and also reward points if the ans helped you.
For this
try like this
if(len <= 10)
return
else
do watevr you want
regards
Aashish Sinha
PS : reward points if helpful
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
78 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.