Send messages with whatsapi.net?

后端 未结 3 1985
长情又很酷
长情又很酷 2020-12-09 17:10

I want to send messages using whatsapi and this was my try

string nickname = \"Test\";
string sender = \"xxxxxxxxxxxxxx\";         
//My Phone Number tryed w         


        
相关标签:
3条回答
  • 2020-12-09 17:39
        WhatsApp wa = new WhatsApp("your number", "your password", "pankaj", false, false);
        wa.OnConnectSuccess += () =>
        {
            Response.Write("connect");
            wa.OnLoginSuccess += (phno,data) =>
            {
                wa.SendMessage("to", "msg");
            };
    
            wa.OnLoginFailed += (data) =>
            {
                Response.Write("login failed"+data);
            };
            wa.Login();
        };
        wa.OnConnectFailed+= (ex)=>
        {
            Response.Write("connection failed");
        }
    
    0 讨论(0)
  • 2020-12-09 17:44

    download installer for generate password https://github.com/mgp25/WART from this link

    after that pass your mobile no and password which you got. and pass user detail like his no or msg in constructor in whatsapp object.

    it will work for you. try with it.

    0 讨论(0)
  • 2020-12-09 17:50

    After the connect put the command to Login. I resolved this way:

    me.connect(); 
    me.login(null);
    
    0 讨论(0)
提交回复
热议问题