Foxtable(狐表)用户栏目专家坐堂 → 关于序号列自动调整


  共有2154人关注过本帖树形打印复制链接

主题:关于序号列自动调整

帅哥哟,离线,有人找我吗?
有点蓝
  1楼 | 信息 | 搜索 | 邮箱 | 主页 | UC


加好友 发短信
等级:超级版主 帖子:107133 积分:544908 威望:0 精华:9 注册:2015/6/24 9:21:00
  发帖心情 Post By:2021/1/4 11:52:00 [显示全部帖子]

Dim r As Row = Tables("表A").InsertNew()
dim idx as integer =1
if r.index > 0 then 
 idx = Tables("表A").rows(r.index-1)("序号") + 1
end if
for i as integer = r.index to Tables("表A").rows.count - 1
Tables("表A").rows(i)("序号") = idx
idx += 1
next

如果要更新的数据多就不要做这种功能了

 回到顶部