Hell All,
I have a complex condition to be applied in my macro. I am new to macros so any guidance will be of help to me.
following is the condition:
please find below sample table:
[TABLE="width: 192"]
<colgroup><col width="64" span="3" style="width:48pt"> </colgroup><tbody>[TR]
[TD="class: xl64, width: 64"]CHECK ID[/TD]
[TD="class: xl64, width: 64"]Remarks[/TD]
[TD="class: xl64, width: 64"]marks[/TD]
[/TR]
[TR]
[TD="class: xl63"]math001[/TD]
[TD="class: xl63"]correct[/TD]
[TD="class: xl63, align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl63"]math001[/TD]
[TD="class: xl63"]wrong[/TD]
[TD="class: xl63, align: right"]0[/TD]
[/TR]
[TR]
[TD="class: xl63"]eng002[/TD]
[TD="class: xl63"]wrong[/TD]
[TD="class: xl63, align: right"]0[/TD]
[/TR]
[TR]
[TD="class: xl63"]math001[/TD]
[TD="class: xl63"]correct[/TD]
[TD="class: xl63, align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl63"]eng002[/TD]
[TD="class: xl63"]wrong[/TD]
[TD="class: xl63, align: right"]0[/TD]
[/TR]
[TR]
[TD="class: xl63"]geo003[/TD]
[TD="class: xl63"]correct[/TD]
[TD="class: xl63, align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl63"]eng002[/TD]
[TD="class: xl63"]wrong[/TD]
[TD="class: xl63, align: right"]0[/TD]
[/TR]
[TR]
[TD="class: xl63"]geo003[/TD]
[TD="class: xl63"]correct[/TD]
[TD="class: xl63, align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl63"]geo003[/TD]
[TD="class: xl63"]correct[/TD]
[TD="class: xl63, align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl63"]geo003[/TD]
[TD="class: xl63"]correct[/TD]
[TD="class: xl63, align: right"]1[/TD]
[/TR]
[TR]
[TD="class: xl63"]sci004[/TD]
[TD="class: xl63"]wrong[/TD]
[TD="class: xl63, align: right"]0[/TD]
[/TR]
[TR]
[TD="class: xl63"]sci004[/TD]
[TD="class: xl63"]correct[/TD]
[TD="class: xl63, align: right"]1[/TD]
[/TR]
</tbody>[/TABLE]
now for every duplicate entry in column CheckID I want to check the remarks, if first entry is "correct" then marks have to be considered as 1 for that entry, if second occurrence of the CheckiD column is also "correct" then NO marks have to be considered for that entry, i.e marks should be 0 and not 1.
If all the remarks value for any particular CheckID is "wrong", then just one of them should be considered and have marks 0, the rest can be ignored.