Here is an example of a report that has a where clause and the code that deletes it.
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
Gender_List = {"M", "F"};
age_list = {12, 13, 14, 15};
Property_List = {"Age", "Height", "Weight"};
w = New Window( "test", VLB = V List Box( Text Box( "A" ), dt << Distribution( Nominal Distribution( Column( :age ) ) ) ) );
For( j = 1, j <= N Items( Gender_List ), j++,
VLB << Append( Text Box( Gender_List[j] ) );
VLB << Append(
LB = LB = Lineup Box( N Col( 2 ), spacing( 10 ),
For( i = 1, i <= N Items( Property_List ), i++,
gb = dt << Distribution( Continuous Distribution( Column( Property_List[i] ) ), where( :Sex == Gender_List[j] ) )
)
)
);
);
whereTb = w << XPath("//TextBox[contains(text(), 'Where(:sex == Gender_List[j])')]");
whereTb << Delete;
See the previous Community Discussion here
Jim