![]() |
ERRORS IN CODE 2003
Hi all gurus, i am getting errors on the code below:
I can click a worksheet and select multiple email addresses but its not working. Set EmailAddr = Application.InputBox("Select Email Addresses - Click on the Email Worksheet" & vbCrLf & _ "Hold down Ctrl Key to select multiple addresses", Type:=8) Neil. |
ERRORS IN CODE 2003
Neil the code will create a range and it can be non contiguous by holding
down the ctrl key and clicking. Try this and it will loop through that range giving the address of each cell. Dim EmailAddr As Range Set EmailAddr = Application.InputBox("Select Email Addresses - Click on the Email Worksheet" & vbCrLf & _ "Hold down Ctrl Key to select multiple addresses", Type:=8) For Each c In EmailAddr MsgBox c.Address Next -- Mike When competing hypotheses are otherwise equal, adopt the hypothesis that introduces the fewest assumptions while still sufficiently answering the question. "Neil Holden" wrote: Hi all gurus, i am getting errors on the code below: I can click a worksheet and select multiple email addresses but its not working. Set EmailAddr = Application.InputBox("Select Email Addresses - Click on the Email Worksheet" & vbCrLf & _ "Hold down Ctrl Key to select multiple addresses", Type:=8) Neil. |
All times are GMT +1. The time now is 04:14 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com