一、邏輯值轉為0或-1:
Dim dst As WinForm.DataList = e.Form.Controls("DataList1")dst.DataTable = DataTables("表A")dst.RowHeaderVisible = 1dst.CheckBoxes = Math.abs(Val(dst.CheckBoxes))-1dst.Build()e.Sender.Text = choose(Math.abs(Val(dst.CheckBoxes))+1,"复选框","行号")
二、日期和數值間轉化:
Dim d,d1 as Dated1 = #4/3/2009#d = Date.FromOaDate(Math.max(Date.today.tooadate,d1.adddays(-5).tooadate))Return d