Avatar

Correct answer by
Level 8

Oh ya no, subformSet's can't be hidden. Didn't see that.

Just take your existing code and add Row3 4 and 6 to hide...Also you don't need the third 'for' loop because your Row5 doesn't repeat.

Should look like this:

for (var a=0;a<Form1._Table1.count;a++){

for (var b=0;b<Form1.Table1.all.item(a)._ActionItemGrp.count;b++){

  if (Form1.Table1.all.item(a).ActionItemGrp.all.item(b).Row5.ClosedDate.rawValue!==null){

   Table1.all.item(a).ActionItemGrp.all.item(b).Row3.presence="hidden";

   Table1.all.item(a).ActionItemGrp.all.item(b).Row4.presence="hidden";

   Table1.all.item(a).ActionItemGrp.all.item(b).Row5.presence="hidden";

   Table1.all.item(a).ActionItemGrp.all.item(b).Row6.presence="hidden";

  }

}

}

Also it might be easier at this point to use plain subforms instead of tables. That way you could just wrap all those 'Rows' in a subform and hide that subform. The only time I use tables is when I want the cells in a row to expand equally during run-time.

Kyle

View solution in original post