Not logged in. · Lost password · Register
Forum: agsXMPP RSS
Page: previous  1  2 
murlin #16
Member since Aug 2011 · 1 post
Group memberships: Members
Show profile · Link to this post
In reply to post ID 3697
Subject: Connection from AGSxmpp to openfire
Good Day!!

I know other users asked the question and fixed it but i read all info and could not resolve mine. I will post my code and maybe someone can help me as well. The  AddHandler xmpp.OnReadXml and  AddHandler xmpp.OnWriteXml not even gets "handled" so no xml code generated. Everything is working on Gtalk settings, but not on any of my 3 openfire servers.

Here my code many of the code commented as i tested different settings:

Imports AGSXmpp
Imports AGSXmpp.protocol.client
Imports AGSXmpp.Collections
Imports AGSXmpp.sasl
Imports AGSXmpp.Xml.Dom
Imports AGSXmpp.Xml.xpnet
Imports AGSXmpp.Xml
Imports System.Threading

Public Class Form1
    Public xmpp As New XmppClientConnection

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

        'Dim jidSender As Jid = New Jid("")

            xmpp.Server = ""
            xmpp.Username = "summer"
            xmpp.Password = "500767"
            'xmpp.Resource = "TheApp"
            'xmpp.Priority = CType(10, Integer)
            'xmpp.Port = Integer.Parse(5222)
            'xmpp.UseStartTLS = False
            'xmpp.UseSSL = False
            'xmpp.RegisterAccount = False
            'xmpp.UseCompression = False
            xmpp.ConnectServer = ""
            'xmpp.AutoResolveConnectServer = True


            AddHandler xmpp.OnReadXml, AddressOf ReadXLM
            AddHandler xmpp.OnWriteXml, AddressOf WriteXLM
            AddHandler xmpp.OnXmppConnectionStateChanged, AddressOf ConnectionStateChanged
            'AddHandler xmpp.OnSaslStart, AddressOf XmppCon_OnSaslStart
            AddHandler xmpp.OnMessage, AddressOf messageReceived
            AddHandler xmpp.OnAuthError, AddressOf loginFailed
            AddHandler xmpp.OnLogin, AddressOf loggedIn
            AddHandler xmpp.OnPresence, AddressOf Presence
            AddHandler xmpp.OnRosterStart, AddressOf Roster

        Catch ex As Exception
        End Try

    End Sub

I didn't add any other subs as addhandlers are not even get triggered.

I forgot one gets triggered after i press connect button second time and replies with a "1" that is connecting as far as i know:

 Private Sub ConnectionStateChanged()
    End Sub

hope anyone can shed light on my problem as well!!

Thank You
Alex #17
Member since Feb 2003 · 4296 posts · Location: Germany
Group memberships: Administrators, Members
Show profile · Link to this post
Are you sure that your Openfire servers are working correctly? Are all firewall rules and port forwarding rules in place?
Did you try to connect to them with an existing XMPP client like Psi, Pandion or others?

Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Page: previous  1  2 
Forum: agsXMPP RSS