发布网友 发布时间:2024-10-26 12:38
共2个回答
热心网友 时间:2024-10-26 12:38
UserVar T=500 "数据长度"
b=1
a=1
Call Plugin.Office.OpenXls("C:\Documents and Settings\Administrator\桌面\自动排序\自动排序.xls")
Do
a=a+1
Text = Plugin.Office.ReadXls(2, a, 1)
//Do
b=b+1
word = Plugin.Office.ReadXls(3, b, 1)
While Tex=wor or b>T
Exit Do
Wend
If b>T Then
aaa = "缺抄"
Else
aaa = Plugin.Office.ReadXls(3, b, 2)
End If
Call Plugin.Office.WriteXls(1, 1, 1, Text)
Call Plugin.Office.WriteXls(1, 1, 2, aaa)
While a>T
Exit Do
Wend
Loop
Sub OnScriptExit()
Call Plugin.Office.CloseXls()
MessageBox "数据已排好"
End Sub
热心网友 时间:2024-10-26 12:34
在white 前+do 就行了
UserVar T=500 "数据长度"
b=1
a=1
Call Plugin.Office.OpenXls("C:\Documents and Settings\Administrator\桌面\自动排序\自动排序.xls")
Do
a=a+1
Text = Plugin.Office.ReadXls(2, a, 1)
Do
b=b+1
word = Plugin.Office.ReadXls(3, b, 1)
Do While Tex=wor or b>T
Exit Do
Loop
If b>T Then
aaa = "缺抄"
Else
aaa = Plugin.Office.ReadXls(3, b, 2)
End If
Call Plugin.Office.WriteXls(1, 1, 1, Text)
Call Plugin.Office.WriteXls(1, 1, 2, aaa)
DO While a>T
Exit Do
Loop
Sub OnScriptExit()
Call Plugin.Office.CloseXls()
MessageBox "数据已排好"
End Sub