给个思路吧:将PX = Eval(Eval(Eval(Eval(Y & Chr(47) & Sin(af)) & Chr(42) & Cos(bf)) & Chr(47) & Eval((1.6 & Chr(42) & Sqr(2#)))) & Chr(42) & 100)写进VBS,然后调用。'VBPrivate Declare Sub Sleep Lib "kernel32" Alias "Sleep" (ByVal dwMilliseconds As Long)Private Sub XXX'……open app.path & "\runvbsOutPut.txt" for output as #1write #1,myeval 'myeval为输入VBS的字符串close #1shell app.path & "\runvbs.vbs" '打开VBS文件sleep 500 '暂停执行0.5秒,让VBS运行完成open app.path & "\runvbsInPut.txt" for input as #1Input #1,myevalvalue 'myevalvalue为VBS输出的某东西close #1'……End Sub''''''VBS'……Dim myeval,myevaloutputOpen app.path & "\runvbsOutPut.txt" For input as #1Input #1,myevalclose #1myevaloutput=eval(myeval)Open app.path &"\runvbsInPut.txt" For out put as #1write #1,myevalvalueclose #1'………………大概就这样吧
阅读全文 >