恭喜,你发布的帖子
发布于 2021-03-29 16:42:25
1楼
终于求教高人找出了原因,特记录如下,方便后来者:
PCS7 v9.0之后的版本升级更新后,数据库的表结构也发生了变化,原有列向后移了一列
将objRecSet(2)objRecSet(2)objRecSet(3)改为相应的objRecSet(3)objRecSet(3)objRecSet(4)即恢复正常
If intNumberOfPrimaryColumns <> 0 Then
If intCurrentID <> C_COUNT Then
Sheets(1).Cells(i, intCurrentPosition) = objRecSet(3).Value
Sheets(1).Cells(i, intCurrentPosition).NumberFormat = "0.00"
Else
If strInterval = "0" Then
Sheets(1).Cells(i, intCurrentPosition) = "1"
Else
Sheets(1).Cells(i, intCurrentPosition) = objRecSet(3).Value
End If
End If
'If "Quality" was selected, enter it in the following column (not for "Count")
If boolQualitySelected = True And intCurrentID <> C_COUNT Then
Sheets(1).Cells(i, intCurrentPosition + 1) = Hex$(objRecSet(4).Value)
End If
End If
请填写推广理由:
分享
只看
楼主