ZetDeveloper / WebWhatsappBot

Core to automatize whatsapp - working 11/2018
MIT License
69 stars 31 forks source link

Some updates may be useful #15

Open derodevil opened 6 years ago

derodevil commented 6 years ago
  1. Method GetQRImageRAWis not working. I'm trying to change to driver.FindElement(By.XPath("//*[@id=\"app\"]/div/div/div[2]/div[1]/div[2]/div/img")); and it's now working
  2. To check if the phone is connected or successfully scanned I'm using this code (changing the old one)
try
                {
                    if (driver.FindElements(By.XPath("//*[@id=\"app\"]/div/div/div[2]/div[1]/div[3]/label/input")).Count > 0)
                        return false;

                    if (driver.FindElements(By.ClassName("icon-alert-phone")).Count > 0)
                        return false;

                    return true;
                }
                catch (Exception ex)
                {
                    return true;
                }
ZetDeveloper commented 6 years ago

I am in the process of optimizing some methods