salahawwad90 قام بنشر سبتمبر 2, 2023 مشاركة قام بنشر سبتمبر 2, 2023 السلام عليكم لدي ملف اكسيل فورم ل ارساله سائل نصية الكود يعمل بشكل صحيح ولكن لا يتم لص نص الرساله ارجو المساعدة Private Sub CommandButton1_Click() Dim contact As String Dim text As String ' contact = TextBox1.Value text = TextBox2.Value ' Google Messages ActiveWorkbook.FollowHyperlink Address:="https://messages.google.com" Application.Wait (Now + TimeValue("00:00:10")) ' Call SendKeys("{TAB}", True) Application.Wait (Now + TimeValue("00:00:01")) Call SendKeys("{TAB}", True) Application.Wait (Now + TimeValue("00:00:01")) Call SendKeys("~", True) ' Enter key Application.Wait (Now + TimeValue("00:00:04")) ' Call SendKeys(contact, True) Application.Wait (Now + TimeValue("00:00:04")) ' Call SendKeys("{TAB}", True) Application.Wait (Now + TimeValue("00:00:01")) Call SendKeys(text, True) Application.Wait (Now + TimeValue("00:00:01")) Call SendKeys("~", True) ' Enter key Application.Wait (Now + TimeValue("00:00:04")) End Sub sms.xlsm رابط هذا التعليق شارك More sharing options...
أفضل إجابة أ / محمد صالح قام بنشر سبتمبر 2, 2023 أفضل إجابة مشاركة قام بنشر سبتمبر 2, 2023 جرب هذا الكود المختصر بإذن الله يكون هو المطلوب Private Sub CommandButton1_Click() Dim contact As String, mytext As String contact = TextBox1.Value mytext = TextBox2.Value ' Google Messages ActiveWorkbook.FollowHyperlink Address:="https://messages.google.com/web/conversations/new" Application.Wait (Now + TimeValue("00:00:10")) Call SendKeys(contact, True) Application.Wait (Now + TimeValue("00:00:04")) Call SendKeys("{TAB}", True) Application.Wait (Now + TimeValue("00:00:01")) Call SendKeys("~", True) ' Enter key Application.Wait (Now + TimeValue("00:00:04")) Call SendKeys(mytext, True) Application.Wait (Now + TimeValue("00:00:01")) Call SendKeys("~", True) ' Enter key Application.Wait (Now + TimeValue("00:00:04")) MsgBox "Done by mr-mas.com" End Sub بالتوفيق 3 رابط هذا التعليق شارك More sharing options...
salahawwad90 قام بنشر سبتمبر 2, 2023 الكاتب مشاركة قام بنشر سبتمبر 2, 2023 شكرا أ / محمد صالح الله يبارك فيك الكود 100/100 اذا ممكن الكود يبعث لمجموعة ارقام رسائل مختلفة رابط هذا التعليق شارك More sharing options...
أ / محمد صالح قام بنشر سبتمبر 3, 2023 مشاركة قام بنشر سبتمبر 3, 2023 ممكن تستعمل for ..... next لكن في كل مرة ستفتح نافذة جديدة في المتصفح 1 رابط هذا التعليق شارك More sharing options...
الردود الموصى بها
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.