老师,我用下面的代码实现了选择多个单元格成批录入,我想实现多个单元格成批自由录入,用键盘录入复杂的数字,请您指点。'----------------------------------批量填充-----------------------
Dim t As Table = Tables("当月工资核算表")
For i As Integer = t.TopRow To t.BottomRow
For j As Integer = t.LeftCol To t.RightCol
If t.Rows(i).IsNull(t.Cols(j).Name) Then
t.Value(i,j) = "1"
'Else
'msgbox(i & "-" & j & "已经有值")
End If
Next
Next
表格KeyDownEdit事件,录入完毕按回车
If e.KeyCode = Keys.Enter Then
Dim t As Table = e.Table
Output.Show(t.BottomRow)
For i As Integer = t.TopRow To t.BottomRow
For j As Integer = t.LeftCol To t.RightCol
If t.Rows(i).IsNull(t.Cols(j).Name) Then
t.Value(i, j) = e.text
'Else
'msgbox(i & "-" & j & "已经有值")
End If
Next
Next
End If
老师,清空后录入可以
[此贴子已经被作者于2024/10/10 8:00:24编辑过]
老师,需要事先把内容清空才行,能不能不清空也能修改录入呢?