Dim dr As Row = CurrentTable.Current
Dim per As Integer = dr("工时") / CurrentTable.Compute("Sum(工时)", "主单编号 = '" & dr("主单编号") & "'")
http://www.foxtable.com/help/topics/0393.htm