on 08-05-2014 5:31 AM
Hi ,
Build version M33.104.
I'm trying to pass the parameter value from one variant to another.
Variant 1 of Job 1, has two parameters, which i want to set as out parameters of Job 1 and map it to the duplicate of Store Variant job parameters.
The Variant 1 has a lot of parameters, so i'm trying to iterate through them to the one i want (also because there is no getSAPAbapVariantParametersByName() method is not available, or is it? there is one for selection but not a parameter?)
The following code didn't compile, because of the error: object mismatch between vpar and it.next().
Iterator it = variant.getSAPAbapVariantParameters();
while(it.hasNext()){
SAPAbapVariantParameter vpar = it.next();
if((vpar.getName()).equals("PAR_BUDA")){
//more code where i get the parameter's value
}
Following are my questions:
SAPAbapVariantParameter vpar = (SAPAbapVariantParameter) it.next();
Please help me fix this, or an alternate solution you might have come across.
Thanks
Nanda
Message was edited by: Nanda Kumar
Hi Nanda,
I am not sure what you are trying to do, but if you want to iterate of the values of a variant, you should use getSAPAbapVariantParameterValues().
You can also use getSAPAbapVariantParameterValueByName(<name>) on the SAPAbapVariant to get a specific one.
I do not understand what you are trying to do, you mention variant 1 of job 1 and Out parameters ?
regards,
HP
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi HP,
I have
Variant 1 in Job A
Variant 2 in Job B
Variant 1 has a lot of parameters out of which, one has the values for posting date and another for ID number. Now, i want to get these two values and use the Store variant job to store these two values for the two corresponding parameters for Variant 2.
The values of those two parameters will change everyday.
I used the getSAPAbapVariantParameterValueByName and it solved my issue.
The method's name is confusing, getSAPAbapVariantParameterValueByName threw me off. Could have been better if it was just getSAPAbapVariantParameterByName.
Thanks
Nanda
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.