我遇到以下VBS代码的困难。它只有时才有效,即使如此也很快失败。为什么?为什么这个VBS代码失败,出现“类型不匹配:'CInt''错误?
Dim Butt
Set Butt = CreateObject("InternetExplorer.application")
Butt.visible = True
Butt2 = InputBox("Put the link to one hat you would like to snipe.", "Hat Selection")
Butt3 = InputBox("Enter the maximum amount of Robux you will spend on this hat.", "Maximum Payment")
Dim Proace
Set Proace = CreateObject("Microsoft.XMLHTTP")
Proace.Open "GET", "http://www.roblox.com", False
Proace.Send
Do
Do While Butt.Busy
WScript.sleep 200
Loop
St00f = CInt(Replace(Mid(St00f, (InStr(St00f, ">R$")+3), 8), "</b>", ""))
If St00f <= CInt(Butt3) Then
Butt.Navigate "javascript:WebForm_DoPostBackWithOptions(new%20WebForm_PostBackOptions(""ctl00$cphRoblox$TabbedInfo$UserSalesTab$lstItemsForResale$ctrl0$lnkBuyNow"",%20"""",%20true,%20"""",%20"""",%20false,%20true))"
Exit Do
End If
Loop
Do While Butt.Busy
WScript.sleep 200
Loop
MsgBox("Congratulations! Your snipe was successful! You sniped "&Butt2&" for "&Butt3&" Robux!")
Butt.Quit
Set Butt = Nothing
Set Proace = Nothing
WScript.Quit
错误:
Script: C:\Users\John\Downloads\SingleHatSniper.vbs
Line: 14
Char: 1
Error: Type mismatch: 'CInt'
Code: 800A000D
Source: Microsoft VBScript runtime error
请帮助我,我不是VBS很大。这很明显,我的朋友帮我写了这个。
复制我不会有任何帮助,但“对接”已是最痛苦的名称可能。我只会在我试图调用方法的时候咯咯笑起来。 “尽管Butt.Busy”? Heeheeheehee。 – Interrobang 2012-02-17 06:07:16
请为您的问题选择一个正确的标题,以让人们对其感兴趣。 “你能通过这个来引导我吗?”对你的问题一无所知。 – deceze 2012-02-17 06:08:10
@Inter与名称为“Interrobang”的配对使得它非常具有启发性,不是吗?-P – deceze 2012-02-17 06:09:48