路径中的非法字符

时间:2015-07-07 15:14:59

标签: vb.net visual-studio-2013

带有问题的代码

Imports System.Net
Public Class Form1
    Dim wc As New WebClient
    Dim s4 As String
    Dim Ex As Object

    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
        Ex.s4 = wc.DownloadString("Api.com/send.php?ip=" & yolo1.Text & "&port=" & yolo2.Text & "&time=" & yolo3.Text)
    End Sub

    Private Sub yolo1_TextChanged(sender As Object, e As EventArgs) Handles yolo1.TextChanged

    End Sub
End Class

我将我的文字改为yolo1,yolo2和yolo3,因为我试图解决问题,但它没有用

1 个答案:

答案 0 :(得分:0)

您需要将协议添加到URL(例如,http或https):

Ex.s4 = wc.DownloadString("http://Api.com/send.php?ip=" & yolo1.Text & "&port=" & yolo2.Text & "&time=" & yolo3.Text)