Jump to content

Send Key "@" problem


 Share

Recommended Posts

Hi @all,

sorry for my bad english but i have a problem.

I just start a little script to send automatically E-Mails via Outlook. The source of the e-mail adresses is outlook.

I write data from a cell in a variable. I display the variable via messagebox and it's all right. I tried to send this String with send keys to Outlook but the Problem is that the "@"char is missing.

Can anybody help me?

Thanks

Best regards

Shark1071

Link to comment
Share on other sites

  • Moderators

Hi, Shark 1071, welcome to the forum. Check out the OutlookEX UDF from Water. This should greatly ease what you're trying to do.

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

HI,

thank you @all.

my script is a quick and dirty solution because i have no time to script. I take a better solution in future, but now i must use this easy way.

My Problem is ther fu**** @char.

I tried to send the @char particular via --- Send("{@}") But the @char wasn't send to outlook :-(

My System:

- Win7 64-bit

- Excel2010

- Outlook2010

- SciTE-Lite

Version 2.28

Can you help me with my quick and dirty solution?

Best regards

Shark1071

EDIT:

Send('@',1) --> doesn't solve the problem. :-(

The @char wasn't send.

Edited by Shark1071
Link to comment
Share on other sites

  • Moderators

Hi, Shark1071. Please post what you have written thus far. This will help us help you :)

Edit:

This is a lousy way to do it, but the @ sign is sent. Please show us your code so we can see where it is breaking.

WinActivate("Inbox")
Send("^n")
Send("Someguy@msn.com")
Edited by JLogan3o13

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

@Jlogan3o13: Did you mean the script?

That's the script:

$xlsdir= "c:Testtest.xlsx"

$zaehlen=0

$i=0

;Excel öffnen

$app = ObjCreate("Excel.application")

$app.Visible = true

$open = $app.Workbooks.Open _

($xlsdir)

$answer= inputbox("Mailanzahl", "Bitte Anzahl an Mails eingeben","","",-1,-1,0,0)

For $i = 1 to $answer

$zaehlen = $zaehlen + 1

$RENR=$app.Cells($zaehlen,1).Value

$Bestellnummer=$app.Cells($zaehlen,2).Value

$Mail=$app.Cells($zaehlen,3).Value

$Kundenname=$app.Cells($zaehlen,4).Value

WinActivate("Posteingang")

sleep(500)

Send("!3")

sleep(500)

msgbox(4096, "mailadresse", $Mail)

Send($Mail)

Send("{@}")

sleep(500)

Send("{TAB 2}")

Send($Bestellnummer)

Send("!i")

Send("a")

Send("f")

sleep(800)

Send("U:Test2Rechnung "&$RENR)

sleep(800)

Send("{enter}")

sleep(500)

Send("!s")

sleep(500)

Next

Link to comment
Share on other sites

  • Moderators

Hi, Shark1071. It seems you are reading the list of names from the Excel file and trying to put them into the TO: line in AutoIT, is this accurate? Can you post a screenshot of the excel contents?

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Hi JLogan3o13,

here the screenshot of my Excel Content:

Posted Image

"C" is the problem.

Send($Mail) to Mailadress Outlook it will be displayed: xxxxvscz2qn1j31marketplace.amazon.de :-(

Send("{ASC 064}") --> works. All other solutions didn't work :-(

Edited by Shark1071
Link to comment
Share on other sites

  • Moderators

Hi, Shark1071. I have copied over your original script, the relevant portion is shown below. Aside from translating a few things to English, I didn't change much. This portion enters the email addresses with the @ symbol for me just fine.

$xlsdir= @DesktopDir & "test.xls"
$count=0
$i=0
;Excel öffnen (Open Excel)
$app = ObjCreate("Excel.application")
$app.Visible = true
$open = $app.Workbooks.Open($xlsdir)
$answer= inputbox("Mail No.", "Please enter the number of messages","","",-1,-1,0,0)


For $i = 1 to $answer
$count = $count + 1
$RENR=$app.Cells($count,1).Value
$order=$app.Cells($count,2).Value
$Mail=$app.Cells($count,3).Value
$name=$app.Cells($count,4).Value

WinActivate("Inbox")
sleep(500)
Send("^n") ;<---is this to open a new email??? For English version is it CTRL+N
sleep(500)
msgbox(4096, "mailadresse", $Mail)
Send($Mail)
sleep(500)
Send("{TAB 2}")
Send($order)
Next

I would still say that if you took a little time to learn the OutlookEX UDF, you would save yourself a ton of headache :)

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

Hi JLogan3o13,

thank you very much.

This script doesn't work with my Outlook. The @char was deleted by sending the mailadress. I found a third party supplier who take my job with sending E-Mail.

Apart from that I read some things about OutlookEX UDF. For interest I will learn OutlookEX UDF in the future. Thanks again for your help.

BR

Shark1071

Link to comment
Share on other sites

If you have any problems with the OutlookEX UDF, just post in the thread and I will be happy to assist.

My UDFs and Tutorials:

Spoiler

UDFs:
Active Directory (NEW 2022-02-19 - Version 1.6.1.0) - Download - General Help & Support - Example Scripts - Wiki
ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts
OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki
OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download
Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki
PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki
Task Scheduler (NEW 2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki

Standard UDFs:
Excel - Example Scripts - Wiki
Word - Wiki

Tutorials:
ADO - Wiki
WebDriver - Wiki

 

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...