Here is an example based on the Big Class data table that does what I think you want.
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
// make the number of graphs different for males
dt << select where( :sex == "M" & :age >=16 );
dt << delete rows;
New Window( "filter test",
Data Filter Context Box(
H List Box(
dt << Data Filter(
Local,
Add Filter(
columns( :sex )
),
Mode( Select( 0 ), Show( 1 ), Include( 1 ) )
),
V List Box(
t = Text Box( "0 Rows Excluded" ),
gb =Graph Builder(
Size( 528, 490 ),
Show Control Panel( 0 ),
Variables( X( :weight ), Y( :height ), Wrap( :age ) ),
Elements( Points( X, Y, Legend( 27 ) ), Smoother( X, Y, Legend( 28 ) ) )
)
)
)
)
);
updatetext = Function( {},
rs = t << Get Row States();
n = 0;
For( ii = 1, ii <= N Rows( rs ), ii++,
If( Excluded( As Row State( rs[ii] ) ),
n
++)
);
t << Set Text( Char( n ) || " Rows Excluded" );
);
rsupdate = Function( {a},
(gb << xpath( "//FrameBox") ) << frame size( 200,150);
);
rsh = t << Make Row State Handler( dt, rsupdate );
updatetext();
Jim