2013-03-19 45 views
0

我試圖連接到服務器上有@在用戶名和我每次得到該錯誤,任何想法?步驟XMPP禁止字符串字符U + 0040(@)Jabber .NET

With jcSender 
     .User = username 
     .Password = password 
     .NetworkHost = "chat.na1.lol.riotgames.com" 
     .Port = 5223 
     .SSL = True 
     .PlaintextAuth = True 
     .Resource = "xiff" 
     .AutoReconnect = True 
     .AutoRoster = True 
     .AutoPresence = True 

    End With 

回答

0

通過使用JID

Public Function Leaguelogin(ByRef USER As String, ByRef PASSWORD As String) 


    Dim account As New jabber.JID(USER + "@pvp.net/xiff") 
    Dim j As New JabberClient 
    Try   

     j.AutoPresence = True 
     j.AutoLogin = True 
     j.Server = "pvp.net" 
     j.NetworkHost = "chat.na1.lol.riotgames.com" 
     j.SSL = True 
     j.Port = 5223 
     j.PlaintextAuth = True 

     j.User = account.User 
     j.Password = "AIR_" + PASSWORD 
     j.Connect() 
     j.Login() 
     j.IsAuthenticated = True 



    Catch ex As Exception 
     MsgBox(ex.Message) 
    End Try 






End Function 
解決它