데이터 세트의 셀 구독안녕 모두,
데이터 세트에서 셀을 구독하려했지만 결코 작동하지 않았습니다. 예를 들어, 일부 특정 셀의 값이 변경되었다는 메시지를 받고 싶습니다. 다음은 그 예입니다.
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
New Window( "Example",
TB=Table Box(
Data Table Col Box( :height )
)
);
TB<<SET cell="" changed="" function=""></SET>"높이"열의 값을 변경하면 데이터 표 col 상자의 해당 값이 변경됩니다. 그러나 값이 변경되는 동안 경고 창이 팝업되지 않습니다. 기본적으로, 하나 또는 여러 개의 셀에 대해 Subscribe ()와 같은 데이터 테이블에서 메시지를 수신하고 싶습니다. 어떤 아이디어든지 appriciated 될 것이다.
다시 : 데이터 집합에서 셀 구독이 두 가지 솔루션은 훌륭하고 저에게 효과적입니다. 다시 한번 도움을 주셔서 감사 드리며 제게 많은 도움이되었습니다!다시 : 데이터 집합에서 셀 구독나는 그것을 좋아한다!
다시 : 데이터 집합에서 셀 구독"Set Cell Changed Function"은 Scripting Index에 나열 되었음에도 불구하고 Data Table Col Box ()에 대해 작동하지 않는 것 같습니다.
다음은 데이터 테이블의 두 (숨겨진) 열에 대한 대안에 대한 아이디어입니다.
dt = Open("$SAMPLE_DATA/Big Class.jmp");
dt << New Column("orig_height", values(:height << get values), hide(1));
dt << New Column("on_change",
Formula(
If(height != orig_height,
New Window("Warning", Text Box("The cell value has been changed"));
.;
)
),
hide(1)
);
New Window("Example", Table Box(dtcb = Data Table Col Box(:height)));다시 : 데이터 집합에서 셀 구독어쨌든 데이터 테이블의 데이터 값을 직접 변경 한 다음 테이블 상자 ()의 변경에 영향을 주도록 알았습니다. 그러나 아래는 약간 이상한 일이지만 아래는 끝났습니다 ......... JMP 커뮤니티의 다른 회원이이 문제를 해결하는보다 직접적인 방법을 원합니다.
Names Default To Here( 1 );
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
// Setup a matrix of the current values
holdMatrix = dt:Height << Get Values;
// A Graphics Script will be triggered every time a
// graph changes.
// Therefore, it can be used to trigger a change in
// a data table
// Open a graph that will have a data point for every
// entry in the data table.
cc = Control Chart(
Sample Size( 1 ),
KSigma( 3 ),
Chart Col( :height, Run Chart( Show Center Line( 0 ) ) )
);
// The chart is not intended to be displayed, only used as
// a trigger. Therefore it needs to be hidden. If an
// "Invisible" element is added to the chart, the graphics
// trigger does not seem to work, however, if the "show window"
// message is sent, the Graphics Script continues to work
Report( cc ) << show window( 0 );
// Add a script to the Chart, to make the changes in
// the Table Box
Report( cc )[FrameBox( 1 )] << Add Graphics Script(
ncb << delete;
tb << append( ncb = Number Col Box( "string", dt:height << get values ) );
// If any value in the data tables Height column changes,
// this If statement will detect it
If( Min( holdMatrix == dt:height << get values ) == 0,
New Window( "Warning", Text Box( "The cell value has been changed" ), );
holdMatrix = dt:height << get values;
);
);
// Open the display window, with the desired table box
nw = New Window( "Example",
TB = Table Box(
ncb = Number Col Box( "string", dt:height << get values ),
)
);
// When the display window is closed, cleanup the
// environment by closing the trigger chart
nw << on close( Report( cc ) << close window );
다시 : 데이터 집합에서 셀 구독안녕 짐,
좋은 아이디어에 감사드립니다. 그러나, 특정 테이블의 값이 변경되면 데이터 테이블에서 값을 연결하여 데이터 테이블 col 박스와 동일한 작업을 수행하려고했습니다. 따라서 데이터는 사용자의 키 입력 대신 데이터 테이블에 직접 업데이트됩니다. 혼란을 드려 죄송합니다.
손추천
다시 : 데이터 집합에서 셀 구독이 문제는 테이블에 대해 편집 가능한 Col Box ()를 사용하지 않는 것 같습니다. 데이터 표 Col Box ()를 Number Col Edit Box ()로 변경했고 사용자가 지정한 기능이 작동합니다.
names default to here(1);
dt = Open( "$SAMPLE_DATA/Big Class.jmp" );
New Window( "Example",
TB=Table Box(
number Col Edit Box( "string",dt:height<<GET values=""></GET>