Skurcey
Messages postés12Date d'inscriptionmercredi 7 avril 2004StatutMembreDernière intervention 9 mars 2006
-
27 janv. 2006 à 10:03
Skurcey
Messages postés12Date d'inscriptionmercredi 7 avril 2004StatutMembreDernière intervention 9 mars 2006
-
28 janv. 2006 à 18:17
Quand je me connecte a un serveur irc, je recois un peu de reponse du serveur puis j ai une erreur qui me dis que un thread ne peux etre execute depuis un autre thread:
Skurcey
Messages postés12Date d'inscriptionmercredi 7 avril 2004StatutMembreDernière intervention 9 mars 2006 27 janv. 2006 à 15:52
Ok, j ai resolu mon probleme, mais maintenant je ne sais pas comment recuperer la liste des channels, je dois ouvrir une nouvelle connection ou qulque chose comme ca?
Je n'ai reussi a avoir une reponse du serveur apres mon send.
namespace Irc
{
public partial class w_main : Form
{
public w_main()
{
InitializeComponent();
cPage._tabControl = main_tabcontrol;
cPage test = new cPage("irc.voidzero.com", 6667);
}
}
public class cPage
{
public static TabControl _tabControl;
public static System.Collections.ArrayList _List = new System.Collections.ArrayList();
private TabPage _page;
private RichTextBox _text;
private TextBox _input;
private string _url;
private int _port;
Skurcey
Messages postés12Date d'inscriptionmercredi 7 avril 2004StatutMembreDernière intervention 9 mars 2006 28 janv. 2006 à 11:28
Apparement, je ne peux utiliser l'ajout d'un texte a partir d'un thread, comment dois je faire? j'ai cru comprendre que je devrais utiliser append et invoke mais j avoue, je suis largue...
Skurcey
Messages postés12Date d'inscriptionmercredi 7 avril 2004StatutMembreDernière intervention 9 mars 2006 28 janv. 2006 à 18:17
QUand j'essaye en local, ca marche bien mais quand j'essaye en me connectant a un serveur irc, je n'obtiend pas de reponse a la commande NICK ou USER, alors qu'avec telnet, oui.
Si jamais, voila mon code:
namespace Irc
{
public partial class w_main : Form
{
public w_main()
{
InitializeComponent();
cPage._tabControl = main_tabcontrol;
cPage test = new cPage("irc.voidzero.com", 6667);
}
private void main_toolitem_ok_Click(object sender, EventArgs e)
{
if (main_toolitem_url.Text != string.Empty)
{
cPage page = new cPage(main_toolitem_url.Text, int.Parse(main_toolitem_port.Text));
}
else
{
cPage page = new cPage(int.Parse(main_toolitem_port.Text));
}
}
private void main_toolitem_help_Click(object sender, EventArgs e)
{
MessageBox.Show("Pour lancer un onglet client:\n URL + port\nPour un onglet serveur:\n Ne pas mettre d'URL et ne pas oubliez d'enlever les ports du firewall.");
}
}
public class cPage
{
public static TabControl _tabControl;
public static int _bufLength = 512;
public static System.Collections.ArrayList _list = new System.Collections.ArrayList();