XMLport Import Text Element not clearing itself - still filled on next loop

bennybbennyb Member Posts: 2
Hello I got a problem while importing an xml file. Somehow I can't find anyone having the same problem on google ._.

So my structure is following

- M

I do processing in the M - Import::OnAfterAssignVariable()
Now let's assume DATA1 is always filled and DATA2 like every third loop only. So it's filled in M1 and M4, but empty in M2 and M3.
My problem now is, that DATA2 gets a value in M1 and now has the same value in M2 and M3.
How can I prevent that without making a CLEAR for every variable that could be empty?
The element doesn't come in M2 and M3 - so it doesn't clear itself I think?

DATA1 (fills with 1)
DATA2 (fills with XYZ)
DATA 1 (fills with 2)
DATA 2 is not provided, so it keeps the value of M1 DATA2 (XYZ)
DATA 1 (fills with 3)
DATA 2 (fills with ASD)

Is there any workaround?


  • lubostlubost Member Posts: 600
    If Data2 is globally defined variable, never clears itself.
  • bennybbennyb Member Posts: 2
    lubost wrote: »
    If Data2 is globally defined variable, never clears itself.

    It is an element in the XMLport structure, not a global defined by myself. It fills itself by importing the xml file.
  • rxqrxqrxq_zydrxqrxqrxq_zyd Member Posts: 16
    you can reset all field (DATA2.INIT) with INIT before import any fields VALUE
Sign In or Register to comment.