> Hi foxie members, thanks men for your help, God bless you all.
> I have a problem
> i have this grid in VFP 9.0 that contains several students records. I want when i enter the marks ie a numeric value like 68 or 56 or 89 etc, the grid column called grade should grade that value approriately eg Pass, Credit, or Distinction, i have included this code in the column.header.text-click method. The grid is working well in grading but the problem is that when i click in the next grid row then the value in the upper row is inserted in the current row ie the clicked row. How can i solve this
> Thanks
> Be heard and be seen
You can get the text such as as 'Pass', to appear in an extra column:
Create a table "Grades" of the grades:
score1 score2 grade
50 62 Pass
63 71 Credit
72 85 Distinction
Set the ControlSource of the extra column to a procedure name 'GetGrade(some column name from the Grid.s recordsource)'
Procedure GetGrade (score)
SELECT grade FROM Grades WHERE m.score BETWEEN score1 AND score2 INTO ARRAY aScore
RETURN aScore()
Set the col,ummn's Sparse property to .F.
-Anders