Help with allowedValues in Assign Resources Form

I have 4 resources:

Resource 1

Resource 2

Resource 3

Resource 4

From the User's Resource Assignment Field in the generic Tabbed User Form; Resources 2-4 are only valid chooses if Resource 1 has already been assigned and that account created. Therefore, Resources 2-4 are dependent on Resource 1.

I need to find a way to keep Resources 2-4 hidden in the allowedValues field until the Resource 1 account is assigned and created, and then make Resources 2-4 visible in the allowedValues field.

I have been able to remove just a single resource out of the allowedValues field, so far. The XPress code that I have so far:

<remove>

<invoke name='getUnassignedResource' class='com.waveset.ui.FormUtil'>

<ref>:display.session</ref>

<map>

<s>currentRoles</s>

<ref>waveset.roles</ref>

<s>currentResourceGroups</s>

<ref>waveset.applications</ref>

<s>current</s>

<ref>waveset.resources</ref>

<s>original</s>

<ref>waveset.original.resources</ref>

</map>

</invoke>

<cond>

<isnull>

<ref>Resource1.username</ref>

</isnull>

<s>Resource2</ref>

</cond>

</remove>

[1478 byte] By [higgledy21701] at [2007-11-26 9:52:01]
# 1

Use removeAll to remove multiple resources

<removeAll>

<invoke name='getUnassignedResource' class='com.waveset.ui.FormUtil'>

<ref>:display.session</ref>

<map>

<s>currentRoles</s>

<ref>waveset.roles</ref>

<s>currentResourceGroups</s>

<ref>waveset.applications</ref>

<s>current</s>

<ref>waveset.resources</ref>

<s>original</s>

<ref>waveset.original.resources</ref>

</map>

</invoke>

<cond>

<isnull>

<ref>Resource1.username</ref>

</isnull>

<list>

<s>Resource2</s>

<s>Resource3</s>

<s>Resource4</s>

</list>

</cond>

</removeAll>

chits98 at 2007-7-7 1:06:03 > top of Java-index,Web & Directory Servers,Directory Servers...
# 2
Thanks.
higgledy21701 at 2007-7-7 1:06:03 > top of Java-index,Web & Directory Servers,Directory Servers...
# 3
removeAll did work. Not sure why.
higgledy21701 at 2007-7-7 1:06:03 > top of Java-index,Web & Directory Servers,Directory Servers...