Iranian Programming Support

Welcome To Csharp TeaM Forum.
For Use All Forum Posts And See Links
Please Register
Thanks
www.Programming.MrForum.net
Csharp TeaM Administrator
Iranian Programming Support

Csharp TeaM

Top posting users this month

Latest topics

» html to c# source code convert help
by launchar Tue Dec 06, 2016 7:22 am

» User input
by nesraz Sun Dec 20, 2015 8:39 am

» darkhaste source mediaplayer baraye b4a
by parham01 Tue Dec 15, 2015 10:31 am

» Tolide esme file gheire tekrari
by sajjad3011 Fri Jul 31, 2015 5:00 pm

» 368 library basic 4 android
by alimusavi71 Fri Jul 17, 2015 6:45 pm

» نرم افزار دریافت لایسنس آنتی ویروس نود 32
by programmer-x Wed Jul 15, 2015 3:19 pm

» help for java applications
by launchar Wed Jul 01, 2015 12:25 am

» Nimbuzz id Maker auto Captcha & Auto add FlooD & id BloCker
by briant Sat Jun 20, 2015 12:46 pm

» best mobile server v.1.0.0 persian edition
by programmer-x Fri Jun 19, 2015 12:41 am

» plz help me i neez xml code for spy bot
by alone Sun Mar 22, 2015 9:30 pm

» Dialogs Lib {Basic 4 Android}
by abdo0o Mon Mar 09, 2015 4:02 pm

» Room + PV Flooder Nimbuzz 2015
by sholeh Sat Feb 21, 2015 8:06 am

» PV Flooder Nimbuzz 2015
by sholeh Sat Feb 21, 2015 8:03 am

» سی شارپ سورس
by tr0 Wed Dec 24, 2014 12:15 pm

» help plz auto maker ids
by launchar Wed Dec 17, 2014 5:57 pm

» Join Multi Id To Room + Captcha [ Badbuzz Team ] In Seri Ba AgsXMPP !!
by abdo0o Fri Dec 12, 2014 4:47 am

» Amoozesh Ersale Sms Dar B4a
by abdo0o Fri Dec 12, 2014 4:43 am

» help me pls mehran brother
by launchar Wed Dec 03, 2014 6:36 pm

» plz help code Refresh captcha join Room
by ayad53 Wed Dec 03, 2014 12:24 pm

» please Help Me For AutoCaptchaa kardan IdMaker
by abdo0o Tue Dec 02, 2014 12:12 pm

» source C# bot addlist sender by ==> Alone_051@n.c
by walahazrat Mon Dec 01, 2014 2:34 am

» s2a sender tro help me pls
by walahazrat Mon Dec 01, 2014 2:28 am

» Help For {Data id } C# asixmpp.dll
by abdo0o Sun Nov 30, 2014 11:17 pm

» Help C# {Join & Left With Remoter}
by $iahi Tue Nov 25, 2014 10:31 am

» Source Nimbuzz User Searcher By Mehr,an [ Badbuzz TeaM ]
by waseemmalik Wed Nov 19, 2014 11:35 am


    Help me to get addlist naqes

    Share
    avatar
    javad1
    Full Member
    Full Member

    Posts : 145
    Points : 254
    Thanks : -1
    Join date : 2013-08-31

    Open Help me to get addlist naqes

    Post by javad1 on Sun Mar 30, 2014 3:31 am

    ¥slm
    Az esme topic malome. Tnx
    avatar
    Mehdi Fa
    VB & VB.Net Admin
    VB & VB.Net Admin

    Posts : 87
    Points : 168
    Thanks : 47
    Join date : 2013-07-25

    Open Re: Help me to get addlist naqes

    Post by Mehdi Fa on Sun Mar 30, 2014 4:23 am

    get addliste salemo ke baladi dg?har addlisti Qeyr az Both naghese

    inja Listboxe 1 Addliste Salem va Listboxe 3 Addliste Naghese
    Vb.Net

    Code:
            AddHandler x.OnRosterStart, AddressOf start
            AddHandler x.OnRosterItem, AddressOf addlist
            AddHandler x.OnRosterEnd, AddressOf endd

    Code:
    Private Sub addlist(ByVal sender As Object, ByVal item As agsXMPP.protocol.iq.roster.RosterItem)
            If MyBase.InvokeRequired = True Then
                MyBase.BeginInvoke(New XmppClientConnection.RosterHandler(AddressOf addlist), New Object() {sender, item})
                On Error Resume Next
                If (item.Subscription = agsXMPP.protocol.iq.roster.SubscriptionType.both) Then
                    For i = 0 To ListBox1.Items.Count - 1
                        If (item.Jid.ToString() = ListBox1.Items(i).ToString()) Then
                            ListBox1.Items.RemoveAt(i)
                        End If
                    Next
                    ListBox1.Items.Add(item.Jid.ToString())
                End If
                If (item.Subscription = agsXMPP.protocol.iq.roster.SubscriptionType.remove) Then
                    For i = 0 To ListBox3.Items.Count - 1
                        If (item.Jid.ToString() = ListBox3.Items(i).ToString()) Then
                            ListBox3.Items.RemoveAt(i)
                        End If
                    Next
                    ListBox3.Items.Add(item.Jid.ToString())
                End If
                If (item.Subscription = agsXMPP.protocol.iq.roster.SubscriptionType.from) Then
                    For i = 0 To ListBox3.Items.Count - 1
                        If (item.Jid.ToString() = ListBox3.Items(i).ToString()) Then
                            ListBox3.Items.RemoveAt(i)
                        End If
                    Next
                    ListBox3.Items.Add(item.Jid.ToString())
                End If
                If (item.Subscription = agsXMPP.protocol.iq.roster.SubscriptionType.none) Then
                    For i = 0 To ListBox3.Items.Count - 1
                        If (item.Jid.ToString() = ListBox3.Items(i).ToString()) Then
                            ListBox3.Items.RemoveAt(i)
                        End If
                    Next
                    ListBox3.Items.Add(item.Jid.ToString())
                End If
                If (item.Subscription = agsXMPP.protocol.iq.roster.SubscriptionType.to) Then
                    For i = 0 To ListBox3.Items.Count - 1
                        If (item.Jid.ToString() = ListBox3.Items(i).ToString()) Then
                            ListBox3.Items.RemoveAt(i)
                        End If
                    Next
                    ListBox3.Items.Add(item.Jid.ToString())
                End If
            End If
        End Sub

    C#

    Code:
    x.OnRosterStart += start;
    x.OnRosterItem += addlist;
    x.OnRosterEnd += endd;

    Code:
    private void addlist(object sender, agsXMPP.protocol.iq.roster.RosterItem item)
    {
       if (base.InvokeRequired == true) {
          base.BeginInvoke(new XmppClientConnection.RosterHandler(addlist), new object[] {sender,item});

          if ((item.Subscription == agsXMPP.protocol.iq.roster.SubscriptionType.both)) {
             for (i = 0; i <= ListBox1.Items.Count - 1; i++) {
                if ((item.Jid.ToString() == ListBox1.Items(i).ToString())) {
                   ListBox1.Items.RemoveAt(i);
                }
             }
             ListBox1.Items.Add(item.Jid.ToString());
          }
          if ((item.Subscription == agsXMPP.protocol.iq.roster.SubscriptionType.remove)) {
             for (i = 0; i <= ListBox3.Items.Count - 1; i++) {
                if ((item.Jid.ToString() == ListBox3.Items(i).ToString())) {
                   ListBox3.Items.RemoveAt(i);
                }
             }
             ListBox3.Items.Add(item.Jid.ToString());
          }
          if ((item.Subscription == agsXMPP.protocol.iq.roster.SubscriptionType.from)) {
             for (i = 0; i <= ListBox3.Items.Count - 1; i++) {
                if ((item.Jid.ToString() == ListBox3.Items(i).ToString())) {
                   ListBox3.Items.RemoveAt(i);
                }
             }
             ListBox3.Items.Add(item.Jid.ToString());
          }
          if ((item.Subscription == agsXMPP.protocol.iq.roster.SubscriptionType.none)) {
             for (i = 0; i <= ListBox3.Items.Count - 1; i++) {
                if ((item.Jid.ToString() == ListBox3.Items(i).ToString())) {
                   ListBox3.Items.RemoveAt(i);
                }
             }
             ListBox3.Items.Add(item.Jid.ToString());
          }
          if ((item.Subscription == agsXMPP.protocol.iq.roster.SubscriptionType.to)) {
             for (i = 0; i <= ListBox3.Items.Count - 1; i++) {
                if ((item.Jid.ToString() == ListBox3.Items(i).ToString())) {
                   ListBox3.Items.RemoveAt(i);
                }
             }
             ListBox3.Items.Add(item.Jid.ToString());
          }
       }
    }

    C# age eshteba bood sorry convert kardam





    /* LIFE RUNS ON CODE */
    avatar
    pokhte
    Csharp Admin
    Csharp Admin

    Posts : 139
    Points : 253
    Thanks : 82
    Join date : 2013-06-29
    Age : 22
    Location : IRaN/Fars/KaZerouN

    Open Re: Help me to get addlist naqes

    Post by pokhte on Sun Mar 30, 2014 4:40 am

    bishtare codeha ro alaki neveshti! ba ye IF e saade mishe jamo joresh kard > migim age SubscriptionType barabare BOTH ya REMOVE nabod addesh kone, baghiyash dige mohem nist

    Code:

                if (item.Subscription != agsXMPP.protocol.iq.roster.SubscriptionType.both || item.Subscription != agsXMPP.protocol.iq.roster.SubscriptionType.remove)
                {
                    bool bl = false;
                    for (i = 0; i < ListBox3.Items.Count; i++)
                    {
                        if (item.Jid.ToString() == ListBox3.Items(i).ToString())
                        {
                             bl = true; break;
                        }
                    }
                    if(!bl)
                    ListBox3.Items.Add(item.Jid.ToString());
                }

    va vase inke iteme tekrari tu listemon nabashe rahi ke mirid eshtebahe ke biad aval pakesh kone bad behesh ezafash kone, chekarie kho ?! ye bool mizarim age false bod behesh ezafash kone!.





    There is no where to run. Destiny will be come...

    Sponsored content

    Open Re: Help me to get addlist naqes

    Post by Sponsored content


      Current date/time is Wed Aug 16, 2017 10:16 am