您好我正在編寫以下代碼來實現以下目標。 誰能幫忙。 由於某種原因,代碼無法正常工作。
感謝 Joydeep
客觀的。
我正在打開表 1,然後獲取表 1 的摘要並將其保存到表 2。
現在,對於表 2 中的每一行,我想為表 1 的行著色。
因此,我在表中運行 For 循環以選擇每一行,並基於此嘗試為表 1 的行著色。
我將不勝感激你的幫助。
//// Here is the code I am trying
dt10= open("\\Test\Table1.jmp");
dt11= dt10 << Summary(
Group(:Work Week ),
Freq( "None" ),
Weight( "None" )
);
x= N Row(dt11);
v= N Rows(dt10);
For(i=1,i <=x, i++,
dt11 << Select Rows(i) ;
For (j=1,j<=v, j++, dt10 << current data table();
if ( Row State(dt10,j) == "Selected" , Column( dt10, "Work Week") << Color Cells( i,{j} ));
);
dt11 << clear selection();
);
嘗試這個:
dt10 = Open( "\\Test\Table1.jmp" );
dt11 = dt10 << Summary( Group( :Work Week ), Freq( "None" ), Weight( "None" ) );
x = N Row( dt11 );
v = N Rows( dt10 );
For( i = 1, i <= x, i++,
dt11 << Select Rows( i );
dt10:Work Week << color cells( "Red")
dt11 << clear selection();
);