10-16-04 02:09 AM
Lars,
Thanks!
Basically, the source document sometimes might have an element named
'Topper' and sometimes in may not. If it does not exist, they they don't
want to see it in the destination document.
So, I first used a logical existence functoid and then joined that to a
scripting functoid. So, I have what looks like this:
(Source schema)<Topper> --> Logical Existence Functoid --> Scripting
Functoid --->Destination schema <Topper>
(Source schema)<Topper> --> Scripting Functoid (same scripting funtoid as
above)
Both Topper elements are set to Min Occurs = 0.
The code inside my functoid is:
//param1 is from the logical existence functoid
//param2 is direct from the source schema Topper element
public string DetOutput(bool param1, string param2)
{
if (param1 == true)
{
return param2;
}
else
{
return "JuJu";
}
}
The JuJu is just a temporary test because it looks like the first part of
the 'if' is always getting selected. No matter how I create the input
document, I never see the output document with the value "JuJu".
Norton
"Lars W. Andersen" <lwa@maerskdata_nospamplease_.dk> wrote in message
news:ua3zigesEHA.3460@TK2MSFTNGP15.phx.gbl...
> Hi Norton,
>
> The "..existence" functoid is not enough on its own. You need to use it
> together with e.g. the looping functoid to produce the resulting element.
> If that is what you need to do? I don't fully understand your
> requirements.
> If you describe your problem further I could help you some more.
>
> regards
> Lars
>
> "TheNortonZ" <thenortonz@hotmail.com> wrote in message
> news:OGK3lYesEHA.1400@TK2MSFTNGP11.phx.gbl...
> the
> to
> element
>
>
[ Post a follow-up to this message ]
|